Re: [Haskell-cafe] Problems with installing the correct version of process. Help?

2011-11-19 Thread Albert Y. C. Lai
On 11-11-15 05:56 PM, Blaine wrote: So this is hilarious. This whole time I thought 'warning' meant 'error'. Under some conditions, having multiple versions does not hurt; under some other conditions, it hurts. This is not an unquestionable error. Though, I would recommend against it, unless

Re: [Haskell-cafe] A Mascot

2011-11-15 Thread Albert Y. C. Lai
On 11-11-15 08:01 PM, heathmatlock wrote: http://i.imgur.com/Mib6Q.png Curry had a little lamb, little lamb, little lamb... ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

Re: [Haskell-cafe] Haskell Platform for OSX ?

2011-11-09 Thread Albert Y. C. Lai
On 11-11-09 06:37 AM, dokondr wrote: In case I upgrade to the latest Haskell Platform, what will happen to packages already installed in my ~/.cabal folder? Some of these are quite old and most probably will be incompatible with GHC 7 Does upgrade process remove old and create anew ~/.cabal

Re: [Haskell-cafe] How do you describe systems in general with Haskell?

2011-11-05 Thread Albert Y. C. Lai
On 11-11-05 01:17 PM, Grigory Sarnitskiy wrote: If you are to describe a system, which consists of several subsystems, how do you approach the problem? What types, classes, functions whatever do you introduce? I guess it is a common problem, is there a general method? Just to describe, not

Re: [Haskell-cafe] Message

2011-10-21 Thread Albert Y. C. Lai
On 11-10-21 03:59 AM, Ivan Lazar Miljenovic wrote: 2011/10/21 Goutam Tmvvo1d_poin...@live.com: Would you ever see yourself write a web application like Twitter or Facebook in Haskell? No. But then, I wouldn't write a web application like either of them in _any_ language. +1 The world does

Re: [Haskell-cafe] Message

2011-10-21 Thread Albert Y. C. Lai
On 11-10-21 01:57 PM, aditya siram wrote: Non snarky question - what does it need? On 11-10-21 01:58 PM, Tom Murphy wrote: Ok, I'll bite: what's it need? Thank you for asking. The world needs another tutorial on lazy evaluation for Haskell. There are currently only 0.5, and it is written

Re: [Haskell-cafe] runStateT execution times measurement baffling

2011-10-21 Thread Albert Y. C. Lai
On 11-10-20 01:38 PM, thomas burt wrote: I've been trying to measure execution time for some code I'm running with the StateT monad transformer. I have a function f :: StateT MyState IO a Now, I measure the time it takes to run an invocation of this function from beginning to end, i.e. f = do

Re: [Haskell-cafe] subclasses and classes with same type in instance

2011-10-18 Thread Albert Y. C. Lai
On 11-10-16 01:56 PM, Patrick Browne wrote: I get the same results from Listing 1 and Listing 2 below. I carefully diff'ed the two listings and found no difference except for comments. -- Listing 1- Subclass data Shed = Shed class Building building where addressB :: building -

Re: [Haskell-cafe] Lists concatenation being O(n)

2011-10-13 Thread Albert Y. C. Lai
On 11-10-12 06:50 PM, Yves Parès wrote: [] ++ ys = ys (x:xs) ++ ys = x : (xs ++ ys) To me, we have here something that would be costful in a strict language, but that here, thanks to guarded recursion ((:) being non-strict), doesn't evaluate the first list until it is needed. So let us

Re: [Haskell-cafe] Error in Installing Data.deriveTH

2011-09-16 Thread Albert Y. C. Lai
Two precautions: 1. ghc-pkg check is incomplete: It ignores shadowing problems, which are like 99% of the problems in practice. Skip ghc-pkg check, go straight to ghc -v for the real report card. 2. ghc-pkg unregister has a long-standing bug. I have filed it as

Re: [Haskell-cafe] pattern matching instead of prelude.head

2011-09-16 Thread Albert Y. C. Lai
On 11-09-15 10:24 PM, Michael Litchard wrote: Someone commented on StackOverflow that pattern matching the first element of a list was preferable to head. This makes sense intuitively. Could someone articulate the reason why this is true? if null s then e0 else ...(head s)...(tail s)... is a

Re: [Haskell-cafe] The maximum/minimum asymmetry

2011-09-05 Thread Albert Y. C. Lai
On 11-09-05 12:44 AM, Mario Blažević wrote: I was recently surprised to discover that the maximum and maximumBy functions always return the *last* maximum, while minimum and minimumBy return the *first* minimum in the list. Though not beautifully symmetric, it's beautifully dual!

Re: [Haskell-cafe] Text.Parsec.Prim

2011-08-30 Thread Albert Y. C. Lai
On 11-08-29 12:35 PM, Roly Perera wrote: Cool. I assumed that since I already had Parsec installed as part of the Haskell Platform it wouldn't have made any difference, but actually it sorted it. Thanks a lot! The combination of ghc 6.12.1 and haskell platform suggests it is a pretty old

Re: [Haskell-cafe] installing/reinstalling haskell platform with profiling enabled on windows

2011-08-30 Thread Albert Y. C. Lai
On 11-08-30 10:52 AM, MH wrote: How can I install/reinstall haskell platform with profiling enabled on windows? It already is. Program Files (x86)\Haskell Platform\2011.2.0.1\lib\extralibs\text-0.11.0.6\ghc-7.0.3\libHStext-0.11.0.6_p.a Program Files (x86)\Haskell

Re: [Haskell-cafe] Dynamic loading of module

2011-08-29 Thread Albert Y. C. Lai
On 11-08-29 02:41 AM, Arnaud Bailly wrote: ghc-pkg unregister --force --user template-haskell [...] ghc-pkg unregister --force --user template-haskell I am sorry. I apologize. It was not your fault. It was my fault. unregister --user drops the global instance when there is no user

Re: [Haskell-cafe] GHC API question

2011-08-29 Thread Albert Y. C. Lai
On 11-08-28 11:38 AM, Chris Smith wrote: Okay, I should have waited until morning to post this... so actually, things still work fine when I build without profiling. However, when I build with profiling, I get the segfault. I'm guessing either I need to set different dynamic flags with the

Re: [Haskell-cafe] [xmonad] Cabal install problem

2011-08-29 Thread Albert Y. C. Lai
I am also interested in the complete output of ghc -v and ghc-pkg list -v. Meanwhile, the pros may notice that Configuring Cabal-1.10.1.0... is very suspicious because GHC 7.0.2 comes with exactly Cabal-1.10.1.0, so there is no normal reason why it is being re-installed (cabal-install's

Re: [Haskell-cafe] GHCI Feature Request: Last Successful Compilation State Saved

2011-08-29 Thread Albert Y. C. Lai
On 11-08-27 04:59 PM, aditya siram wrote: Many times I've changed files, loaded them, hit a compilation error and needed, for example, the inferred type signature of some function. Even though that function hasn't been changed I have to either fix my code, undo a bunch of changes or comment out

Re: [Haskell-cafe] Dynamic loading of module

2011-08-28 Thread Albert Y. C. Lai
Y. C. Lai tre...@vex.net mailto:tre...@vex.net wrote: You have too many instances of template-haskell. The important parts are: package ghc-7.0.3-__fc75cf67c86ba2c0d64b07024a18d3__b4 is unusable due to missing or recursive dependencies: template-haskell-2.5.0.0

Re: [Haskell-cafe] Dynamic loading of module

2011-08-28 Thread Albert Y. C. Lai
On 11-08-28 04:53 PM, Brandon Allbery wrote: That'd be expected; you shouldn't simply obliterate package.conf.d, you need to keep ghc's boot libraries (which include itself as a library). If the boot libraries are somehow hosed, you need to reinstall the compiler to get them back. Different

Re: [Haskell-cafe] Dynamic loading of module

2011-08-28 Thread Albert Y. C. Lai
On 11-08-28 10:38 PM, Brandon Allbery wrote: On Sun, Aug 28, 2011 at 22:13, Albert Y. C. Lai tre...@vex.net mailto:tre...@vex.net wrote: On 11-08-28 04:53 PM, Brandon Allbery wrote: That'd be expected; you shouldn't simply obliterate package.conf.d, you need to keep

Re: [Haskell-cafe] Dynamic loading of module

2011-08-26 Thread Albert Y. C. Lai
On 11-08-26 04:51 AM, Arnaud Bailly wrote: D:\projets\ghc -package ghc main.hs --make command line: cannot satisfy -package ghc: ghc-7.0.3-fc75cf67c86ba2c0d64b07024a18d3b4 is unusable due to missing or recursive dependencies: template-haskell-2.5.0.0-7d9b1443ac5ab69e5ed705a487990deb

Re: [Haskell-cafe] Ambiguous module name `System.Directory'

2011-08-26 Thread Albert Y. C. Lai
On 11-08-26 12:00 PM, informationen wrote: How can i resolve this conflict permamently (i know about :set -hide-package ... )? And shouldn't there be a rule in the haskell platform which forbids modules of the same name? Two permanent resolutions, choose one: ghc-pkg hide system-fileio

Re: [Haskell-cafe] Cabal-1.10.1.0 and bytestring-0.9.2.0 hackage problem.

2011-08-25 Thread Albert Y. C. Lai
On 11-08-25 10:42 AM, Bertram Felgenhauer wrote: (or rebuild Cabal / cabal-install starting with 'cabal unpack Cabal; cabal unpack cabal-install') Replacing Cabal will break bin-package-db. Breaking bin-package-db will break ghc (the GHC API). Break means you likely don't run into problems

Re: [Haskell-cafe] bitSize

2011-08-25 Thread Albert Y. C. Lai
On 11-08-25 01:57 PM, Andrew Coppin wrote: Does anybody else think it would be *far* more useful if bitSize applied to an Integer would tell you how many bits that particular Integer is using? Especially given that it can vary? It is useful to know the number of bits used in a value. It is

[Haskell-cafe] do-re-mi

2011-08-24 Thread Albert Y. C. Lai
do, a block, a monad block rec, a knot tied in the block mu, a name that calls itself (mu is pronounced as me in modern Greek) forM_, a long long list to run SO, a state aborting threads (SO is stack overflow) la, a state to follow SO T's, tranformers of monads that will bring us back to do

Re: [Haskell-cafe] Simon PJ in Australia

2011-08-19 Thread Albert Y. C. Lai
On 11-08-19 06:54 AM, Arlen Cuss wrote: You heard it here first; Simon's down here in Aus to eat pizza, university departments, Haskell users groups. Will he leave nothing left!? He is not eating newbies. But I am. I love newbies. ___ Haskell-Cafe

Re: [Haskell-cafe] Overloading in a sub-class

2011-08-17 Thread Albert Y. C. Lai
On 11-08-17 12:10 PM, Patrick Browne wrote: -- Are + and negate part of the signature of Numb1? class Numb0 a = Numb1 a where No. -- Is it possible to override these operations in instances of Numb1? -- Something like: -- instance Numb1 Float where --x + y = y --negate x = x

Re: [Haskell-cafe] library-profiling default

2011-08-07 Thread Albert Y. C. Lai
On 11-08-04 03:06 AM, Tom Doris wrote: Is there a good reason that the default for library-profiling in .cabal/config is set to False? The combination of two defaults -- library-profiling: False -- documentation: False points towards optimizing for people who use applications such as xmonad

Re: [Haskell-cafe] Simple Parsec example

2011-08-07 Thread Albert Y. C. Lai
On 11-08-07 02:44 PM, michael rice wrote: What other imports must I add to get this to run. I can't seem to get it right. [...] import Text.ParserCombinators.Parsec.Prim main = case (parse numbers 11, 2, 43) of Left err - print err Right xs - print (sum xs) numbers = commaSep integer The

Re: [Haskell-cafe] Binding of an integer variable

2011-07-28 Thread Albert Y. C. Lai
Another fun example: let c = 0 : c let b = 1 : 1 : c :show bindings length (take 5 c) :show bindings take 3 c :show bindings ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

Re: [Haskell-cafe] Failure to install Network.CGI

2011-07-18 Thread Albert Y. C. Lai
On 11-07-17 12:29 AM, william murphy wrote: command line: cannot satisfy -package-id network-2.3.0.2-24fdc6b92867c7236e81708f93cae7d0 Look at the output of ghc -v and be very horrified. The problem is not lacking packages or being outdated. The problem is possessing too many packages and

Re: [Haskell-cafe] Category theory as a design tool

2011-06-23 Thread Albert Y. C. Lai
On 11-06-22 12:30 AM, Arnaud Bailly wrote: Are there works/thesis/books/articles/blogs that try to use Cat. theory explicitly as a tool/language for designing software (not as an underlying formalisation or semantics)? Is the question even meaningful? A lot of Doug Smith's works. In short, an

Re: [Haskell-cafe] Haskell Weekly News: Issue 187

2011-06-23 Thread Albert Y. C. Lai
Picky readers we are. I don't mind URL length. And there are ways to have long URLs in-situ without being a big disruption. I hate the borrowed academic practice of saying [0] and giving the URL two hundred lines later. It worked great on paper in hands because I could stick my finger to

Re: [Haskell-cafe] Haskell-Cafe Digest, Vol 93, Issue 58

2011-06-13 Thread Albert Y. C. Lai
On 11-06-08 11:17 PM, Gregory Guthrie wrote: So the implication of the rules: 1) all IO must start from the top level, and there is only one IO 2) you cannot extract anything from an IO Seems to be that the whole program structure becomes a series of do... blocks, which is basically a

Re: [Haskell-cafe] Comment Syntax

2011-06-06 Thread Albert Y. C. Lai
Bearing in mind that the characters that have been used to begin end of line comments include *, /, ;, !, #, %, and $, it's not clear that there's anything _that_ regrettable about -- . Recall that the problem is not with isolated characters, but whole strings. -- a is a comment, --a is a

Re: [Haskell-cafe] Comment Syntax

2011-06-06 Thread Albert Y. C. Lai
On 11-06-06 01:34 PM, Daniel Fischer wrote: On Montag, 6. Juni 2011, 19:08, Albert Y. C. Lai wrote: Recall that the problem is not with isolated characters, but whole strings. -- a is a comment, --a is a comment, but ---a is not. It is. Report, section 2.3: Sorry. Then --| is not a comment

Re: [Haskell-cafe] Comment Syntax

2011-06-04 Thread Albert Y. C. Lai
On 11-06-04 02:20 AM, Roman Cheplyaka wrote: It is, for my taste, a good comment marker, because of its resemblance to a dash. It makes the code look like real text: let y = x + 1 -- increment x COBOL is real text, if that is what you want. ___

Re: [Haskell-cafe] Comment Syntax

2011-06-03 Thread Albert Y. C. Lai
I propose that only {- -} is comment; that is, -- is an operator token and not a marker of comments. Two birds in one stone: 1. Removes the cause of the mistake of writing a haddock comment as --| That is, if no one writes any comment with -- then no one writes any haddock comment with --|

Re: [Haskell-cafe] *GROUP HUG*

2011-06-01 Thread Albert Y. C. Lai
On 11-06-01 07:15 PM, Don Stewart wrote: http://stackoverflow.com/questions/6172004/writing-foldl-using-foldr/6172270#6172270 Thank Graham Hutton and Richard Bird. Another one along the same line: http://www.vex.net/~trebla/haskell/natprim.xhtml Yet one more, along the tangent:

Re: [Haskell-cafe] Lazy Evaluation in Monads

2011-05-31 Thread Albert Y. C. Lai
On a tangent, not doing IO, but food for thought: {-# LANGUAGE FlexibleContexts #-} import Control.Monad.State.Lazy as N import Control.Monad.State.Strict as S gen :: (MonadState [()] m) = m () gen = do gen modify (() :) many = take 3 (N.execState gen []) none = take 3 (S.execState gen

Re: [Haskell-cafe] Enterprise Haskell -- help

2011-05-27 Thread Albert Y. C. Lai
On 11-05-26 12:45 PM, Srinivasan Balram wrote: (ii) Haskell Enterprise Development i.e. how to connect commercial RDBMS and use Haskell along with SQL effectively By the time we finish adding that to a future book, enterprise programmers will have already moved to the like of NoSQL and

Re: [Haskell-cafe] trying to cabal install lambdabot, failure on 'random' package

2011-05-08 Thread Albert Y. C. Lai
On 11-05-08 03:24 AM, Sean Perry wrote: package random-1.0.0.3 requires time-1.2.0.3 package random-1.0.0.3 requires time-1.2.0.4 In addition to unregistering --user random-1.0.0.3, also unregister --user time-1.2.0.4, the real culprit. The real culprit is why you are infected with a

Re: [Haskell-cafe] Can't build Gtk2hs on Windows

2011-05-04 Thread Albert Y. C. Lai
Just 5 weeks ago, http://thread.gmane.org/gmane.comp.lang.haskell.cafe/86738/focus=87456 Did anyone see it? ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

Re: [Haskell-cafe] Interfacing C++ iterators does not work as expected

2011-05-02 Thread Albert Y. C. Lai
On 11-05-02 05:31 PM, Huynh Huu Long wrote: Big thanks, that works for me as well. Doesn't GHC check whether a type is allowed (like CInt,...) or not (like Bool,...)? No, it doesn't, since version 6.10.1:

Re: [Haskell-cafe] Is Harper right that Haskell cannot model the natural numbers?

2011-05-02 Thread Albert Y. C. Lai
On 11-05-02 11:25 PM, Richard O'Keefe wrote: Fair enough, but what about data Nat = Zero | Succ !Nat It works. I say, Harper forgot it. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org

Re: [Haskell-cafe] Python is lazier than Haskell

2011-04-28 Thread Albert Y. C. Lai
On 11-04-27 05:44 PM, serialhex wrote: in ruby they use what some call duck typing if it looks like a duck and quacks like a duck... it's a duck. Python and Javascript also do duck typing. Haskell does Functor typing. A Functor is something that provides an fmap method. List does it, so you

Re: [Haskell-cafe] Python is lazier than Haskell

2011-04-27 Thread Albert Y. C. Lai
On 11-04-27 05:30 AM, Henning Thielemann wrote: I like to apply for the quote of the week. :-) If Haskell is great because of its laziness, then Python must be even greater, since it is lazy at the type level. Using Data.Dynamic, Haskell has a story for laziness at the type level, too.

Re: [Haskell-cafe] HipmunkPlayground compile error

2011-04-27 Thread Albert Y. C. Lai
Perhaps the linker ran out of memory. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

Re: [Haskell-cafe] impoosible dependencies

2011-04-20 Thread Albert Y. C. Lai
On 11-04-20 05:51 PM, Kevin Quick wrote: cabal: dependencies conflict: ghc-6.12.3 requires unix ==2.4.0.2 however unix-2.4.0.2 was excluded because ghc-6.12.3 requires unix ==2.4.1.0 [and later] cabal: dependencies conflict: ghc-6.12.3 requires array ==0.3.0.2 however array-0.3.0.2 was

Re: [Haskell-cafe] HXT and xhtml page encoded in cp1251

2011-04-19 Thread Albert Y. C. Lai
On 11-04-18 05:06 PM, Dmitry V'yal wrote: The readDocument arrow fails with the following message: fatal error: encoding scheme not supported: WINDOWS-1251 Can someone suggest a workaround for my use case? If you have a Handle (from file or Network for example), import

Re: [Haskell-cafe] Questioning seq

2011-04-14 Thread Albert Y. C. Lai
On 11-04-14 01:57 PM, Andrew Coppin wrote: 3. How is pseq different from seq? An example to show that there are non-unique evaluation orders to fulfill the mere strictness promise of seq: import Data.List(foldl') () () = () main = print (foldl' () () (replicate 250 ())) with ghc with

Re: [Haskell-cafe] Parsing HTML tables with HXT

2011-04-10 Thread Albert Y. C. Lai
On 11-04-08 06:29 AM, Dmitry Simonchik wrote: Can someone please help me with getting the value of the table cell with HXT in the following html: table class=tblc tr td class=tdcx/td tdy/td /tr tr td class=tdca/td tdb/td /tr /table I need the value of the second cell in a row that has first

Re: [Haskell-cafe] why are trading/banking industries seriously adopting FPLs???

2011-03-25 Thread Albert Y. C. Lai
On 11-03-25 03:08 AM, Vasili I. Galchin wrote: I am very curious about the readiness of trading and banking industries to adopt FPLs like Haskell: Not only FPL and not only Haskell, but also descendents of APL such as J. Generally also any innovation. Why are they willing to try out

Re: [Haskell-cafe] STM, newArray, and a stack overflow?

2011-03-24 Thread Albert Y. C. Lai
On 11-03-23 05:31 PM, Ketil Malde wrote: Any idea why it works in GHCI? Documentedly, stack limit is 8M, and can be changed by +RTS -K42M (for example). Undocumentedly, certain magic numbers given to -K seem to waive the limit (or set it so high I haven't fathomed). GHC 6.10.4: 4 to 59

[Haskell-cafe] wrong backquote in haskell 2010 report Prelude

2011-03-17 Thread Albert Y. C. Lai
Haskell 2010 report chapter 9 Standard Prelude uses a wrong backquote, e.g., infixl 7 ⋆, /, ‘quot‘, ‘rem‘, ‘div‘, ‘mod‘ Those are U+2018. The grammar (Chapter 3) requires U+0060 and accepts no substitutes, e.g., varop → varsym | ` varid ` ___

Re: [Haskell-cafe] Haskell Platform install instructions

2011-02-25 Thread Albert Y. C. Lai
On 11-02-25 05:40 AM, Michael Snoyman wrote: Some of the dependencies for Yesod (such as haskell-src) require happy. For the Yesod in Five Minutes page[1], I've given instructions to cabal install happy and then cabal install yesod. However, as Xavier Shay pointed out to me, this won't actually

Re: [Haskell-cafe] Proving correctness

2011-02-14 Thread Albert Y. C. Lai
On 11-02-12 09:40 PM, Brandon S Allbery KF8NH wrote: Only up to a point. While most of the responses so far focus on the question from one direction, the other is epitomized by a Knuth quote: Beware of bugs in the above code; I have only proved it correct, not tried it. Knuth's definition of

Re: [Haskell-cafe] Proving correctness

2011-02-14 Thread Albert Y. C. Lai
On 11-02-14 03:03 PM, Pavel Perikov wrote: Sorely, Haskell can't prove logic with it. No predicates on values, guarantee that proof is not _|_. Haskell makes bug free software affordable, that's true. But it's not a proof assistant. Who claimed that Haskell is a proof assistant?

Re: [Haskell-cafe] timely shutdown of timer threads

2011-02-02 Thread Albert Y. C. Lai
On 11-02-02 04:42 PM, Warren Harris wrote: It still seems to me that haskell is lacking when it comes to operations that can wait for multiple conditions. STM opens the avenue to waiting for multiple conditions. import Control.Concurrent import Control.Concurrent.STM import

Re: [Haskell-cafe] timely shutdown of timer threads

2011-02-01 Thread Albert Y. C. Lai
On 11-02-01 02:58 PM, Warren Harris wrote: I have an application that forks a thread to run an activity on a timer. (The activity happens to be Berkeley DB checkpointing, but that's actually beside the point here.) The problem is that when the application wants to quit, I would like my main

Re: [Haskell-cafe] Flushing Cabal's cache

2011-01-22 Thread Albert Y. C. Lai
On 11-01-22 11:31 AM, Aaron Gray wrote: I am on Windows Vista, is it possible to clean or delete Cabal's cache ? Something about [your home directory]\AppData\Roaming\cabal\packages\hackage.haskell.org ___ Haskell-Cafe mailing list

Re: [Haskell-cafe] Problems installing the haskell platform

2011-01-21 Thread Albert Y. C. Lai
On 11-01-19 08:52 AM, Henry Laxen wrote: Greetings. I've been using haskell for about a year now, though I will readily admit I still don't really know what I am doing when I get error messages. Today I decided to reset my haskell environment from scratch, avoiding the debian packages and

Re: [Haskell-cafe] windows network programming

2011-01-21 Thread Albert Y. C. Lai
On 11-01-21 03:13 AM, Tako Schotanus wrote: Just starting out here so I don't know what I'm doing yet, but this one doesn't compile for me. ping.hs:19:13: parse error on input `-' The original code contains no parse error. When you tranfer it to your editor, you may accidentally change

Re: [Haskell-cafe] Where is the CABAL file for haskell-platform 2010.2.0.0?

2011-01-20 Thread Albert Y. C. Lai
On 11-01-20 10:38 AM, Magnus Therning wrote: Where can I find the cabal file for 2010.2.0.0 until 2011.1.0.0 is formally released (or will it be 2011.2.0.0 as the release plan says)? Will the CABAL file for 2010.2.0.0 not be available *at all* after 2011.x.0.0 is released? Start from the real

Re: [Haskell-cafe] Denotational semantics for the lay man.

2011-01-17 Thread Albert Y. C. Lai
On 11-01-17 01:55 PM, David Sankel wrote: I've recently had the opportunity to explain in prose what denotational semantics are to a person unfamiliar with it. I was trying to get across the concept of distilling the essence out of some problem domain. I wasn't able to get the idea across so I'm

Re: [Haskell-cafe] H98, OOHaskell - getting started with objects in Haskell

2011-01-14 Thread Albert Y. C. Lai
On 11-01-13 06:23 PM, gutti wrote: I'm especially interestes in engineering calculation tasks where cellular automata could be used. In that case all u have to do is to give the class the right properties and that let it grow. Such a localised intelligence approach seems to be exactly

Re: [Haskell-cafe] parsec2 vs. parsec3... again

2011-01-13 Thread Albert Y. C. Lai
On 11-01-13 02:07 PM, Permjacov Evgeniy wrote: BTW, how much utf16 text is around? I never found any in wild web. There is a lot of utf16 text in memory chips when you use Windows or Java. In the case of Windows there is also a lot on disk platters as file names. A scanning electron

Re: [Haskell-cafe] UTF-8 BOM

2011-01-04 Thread Albert Y. C. Lai
On 11-01-04 08:08 PM, Tony Morris wrote: I am reading files with System.IO.readFile. Some of these files start with a UTF-8 Byte Order Marker (0xef 0xbb 0xbf). There is System.IO.utf8_bom for that. Of course, then you can't use readFile; but you can use openFile and hGetContents.

Re: [Haskell-cafe] ; in do

2010-12-30 Thread Albert Y. C. Lai
On 10-12-29 11:40 PM, Daryoush Mehrtash wrote: Why do people put ; in do {}, or , in data fields, at the beginning of the line? There was a time I did this to help the auto-indenter. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org

Re: [Haskell-cafe] Reader monad

2010-12-29 Thread Albert Y. C. Lai
On 10-12-29 12:50 PM, michael rice wrote: I think of (r - m a) as a type signature and Int or Bool by themselves as types. So, all type signatures are themselves types? http://www.haskell.org/onlinereport/haskell2010/haskellch4.html#x10-620004 In particular gendecl → vars :: [context =] type

Re: [Haskell-cafe] How to reload module that package has linked in memory?

2010-12-25 Thread Albert Y. C. Lai
On 10-12-25 10:47 AM, Andy Stewart wrote: I use Linker.linkPackages and Linker.getHValue to get symbol value, but looks Linker.getHValue can't get *update* value once current package has linked in memory. So how to make Linker.getHValue can get *update* value and don't need install *new*

[Haskell-cafe] haskell platform windows download url

2010-12-20 Thread Albert Y. C. Lai
On http://hackage.haskell.org/platform/windows.html , the link for download haskell for windows is: http://lambda.galois.com/hp-tmp/2010.2.0.0/HaskellPlatform-2010.2.0.0-setup.exe Is this normal? ___ Haskell-Cafe mailing list

Re: [Haskell-cafe] haskell platform windows download url

2010-12-20 Thread Albert Y. C. Lai
On 10-12-20 04:14 PM, Henk-Jan van Tuyl wrote: On Mon, 20 Dec 2010 19:58:10 +0100, Albert Y. C. Lai tre...@vex.net wrote: On http://hackage.haskell.org/platform/windows.html , the link for download haskell for windows is: http://lambda.galois.com/hp-tmp/2010.2.0.0/HaskellPlatform-2010.2.0.0

Re: [Haskell-cafe] Haskell, Step by Step, Tutorial, Developing a Whole Application

2010-12-16 Thread Albert Y. C. Lai
On 10-12-16 06:49 PM, __kaveh__ wrote: Is there a (or more; the more, the better) tutorial for Haskell, developing a whole application (of any kind: web, windows, console)? There is one developing a whole Scheme interpreter: http://en.wikibooks.org/wiki/Write_Yourself_a_Scheme_in_48_Hours

Re: [Haskell-cafe] dot-ghci files

2010-12-09 Thread Albert Y. C. Lai
Perhaps ghc should also ignore all group-writable *.hs, *.lhs, *.c, *.o, *.hi files. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

Re: [Haskell-cafe] dot-ghci files

2010-12-09 Thread Albert Y. C. Lai
On 10-12-09 01:57 PM, Claus Reinke wrote: Perhaps ghc should also ignore all group-writable *.hs, *.lhs, *.c, *.o, *.hi files. dot-ghci files are *run* if you just start ghci (or ghc -e) in that directory (even if you don't intend to compile, load, or run any Haskell code). Haskell

Re: [Haskell-cafe] the beginning of the end

2010-12-05 Thread Albert Y. C. Lai
On 10-12-05 12:34 PM, Daniel Peebles wrote: Oh yeah, the 2.0 stuff that snobby techies love to hate :) hrrmpf back in my day we programmed in binary using a magnetized needle on the exposed tape! I don't need any of this newfangled bull. I kid! But I am curious to see why people are so

[Haskell-cafe] the beginning of the end (was: Hackage down?)

2010-12-04 Thread Albert Y. C. Lai
On 10-12-04 01:03 PM, Antoine Latter wrote: Here's a Reddit post: http://www.reddit.com/r/haskell/comments/efw38/reminder_hackagehaskellorg_outage_tomorrow_due_to/ This is the second consecutive time a planned downtime is not announced on either mailing lists. This seems to me planned

Re: [Haskell-cafe] Unable to install packages

2010-12-01 Thread Albert Y. C. Lai
On 10-11-30 05:19 AM, Ketil Malde wrote: It seems to me that while there are *three* ways to install stuff: apt-get install, cabal install --global, and cabal install --user, there are just *two* ways things get installed, globally and user(ly?). The obvious solution would be to have three

Re: [Haskell-cafe] Re: Unable to install packages

2010-11-29 Thread Albert Y. C. Lai
On 10-11-28 09:55 AM, Ketil Malde wrote: Joachim Breitnerm...@joachim-breitner.de writes: I would not recommend using --global on Debian/Ubuntu-systems, as it might interfere with packages installed by Debian. But 'cabal install --global' installs in /usr/local/, does it not? And official

Re: [Haskell-cafe] Re: Unable to install packages

2010-11-29 Thread Albert Y. C. Lai
On 10-11-29 03:15 PM, Albert Y. C. Lai wrote: cabal install --global binary apt-get install libghc6-binary-dev They are the same version (at the time of writing, and assume Ubuntu 10.10) and they will fight for the unique throne of binary-0.5.0.2 in the metadata. Oh bother, Debian/Ubuntu's

Re: [Haskell-cafe] Re: Can't install Leksah

2010-11-27 Thread Albert Y. C. Lai
On 10-11-27 09:20 AM, jutaro wrote: ghc is a package, which exposes Ghc-Api as a library. It gets usually installed, when you install Ghc or Haskell platform. As I remeber , it is usually in a hidden state, but ghc-pkg list should show it. Except that Fedora's GHC really doesn't come with the

Re: [Haskell-cafe] How to cabal fetch mtl==2.0.0.0?

2010-11-25 Thread Albert Y. C. Lai
On 10-11-24 08:52 PM, Iain Alexander wrote: F:\Util\Haskellcabal fetch mtl==2.0.0.0 Resolving dependencies... cabal: internal error: could not construct a valid install plan. cabal fetch mtl-2.0.0.0 ___ Haskell-Cafe mailing list

Re: [Haskell-cafe] Downloading web page in Haskell

2010-11-20 Thread Albert Y. C. Lai
On 10-11-20 02:54 PM, José Romildo Malaquias wrote: In order to download a given web page, I wrote the attached program. The problem is that the page is not being full downloaded. It is being somehow intettupted. The specific website and url

Re: [Haskell-cafe] Downloading web page in Haskell

2010-11-20 Thread Albert Y. C. Lai
Most likely you also have the zlib package (cabal-install needs it), so let's use it. Attached therefore.hs import qualified Data.ByteString.Lazy as LB import Codec.Compression.GZip(decompress) import Network.URI(parseURI) import Network.HTTP url =

Re: [Haskell-cafe] Musings on type systems

2010-11-19 Thread Albert Y. C. Lai
On 10-11-19 04:39 PM, Matthew Steele wrote: TAPL is also a great book for getting up to speed on type theory: http://www.cis.upenn.edu/~bcpierce/tapl/ I am no type theorist, and I nonetheless found it very approachable. TAPL is surprisingly easy-going. It is long (many pages and many

Re: [Haskell-cafe] Type Directed Name Resolution

2010-11-10 Thread Albert Y. C. Lai
Typed-directed name resolution brings Haskell closer to a write-only language; that is, an ambiguous phrase made total sense to the author when the author wrote it, but an independent reader will need extraordinary effort to disambiguate. {-# LANGUAGE TypeDirectedNameResolution #-} import

[Haskell-cafe] Rename When Import (was: Type Directed Name Resolution)

2010-11-10 Thread Albert Y. C. Lai
A better solution to import-induced name clashes is Rename When Import. You can already rename the module when importing. Let's rename the imported names too. Assume I want to import this module: module SinisterlyNamedModule where data Parsec = State { stdin :: () } | Cont {

Re: [Haskell-cafe] Rename When Import

2010-11-10 Thread Albert Y. C. Lai
On 10-11-10 02:51 PM, Albert Y. C. Lai wrote: import SinisterlyNamedModule( par...@goodtype(st...@caseone(st...@gfa), c...@casetwo(ru...@gfb, froml...@gfc) ), Sorry, that part was mistaken, and not in line with standard Haskell. Here is the correction

Re: [Haskell-cafe] Cabal and using a throw-away package database during distro package building

2010-11-05 Thread Albert Y. C. Lai
On 10-11-05 06:43 AM, Magnus Therning wrote: runhaskell Setup register --gen-script runhaskell Setup unregister --gen-script [...] Except that the generated register/unregister scripts now also point to my-temp-db, and there seems to be no way to prevent this. I solved it for now

Re: [Haskell-cafe] Haskell is a scripting language inspired by Python.

2010-11-04 Thread Albert Y. C. Lai
On 10-11-03 10:00 PM, Jonathan Geddes wrote: It's called The *Ultimate* Computer Language Guide, and it's on the internets, so it must be correct, right? The correct conclusion: it's on the internets, so it must be LOL. I also invite you to play with my:

Re: [Haskell-cafe] who's in charge?

2010-10-27 Thread Albert Y. C. Lai
On 10-10-27 06:31 AM, Günther Schmidt wrote: this may be an odd question to some, but I think it's actually quite an un-extraordinary one. Who's in charge? Of Haskell I mean. If there was some alien from Planet Java to land on Planet Haskell and demand to be taken to our leader, whom would we

Re: [Haskell-cafe] capture of idioms and patterns

2010-09-24 Thread Albert Y. C. Lai
On 10-09-23 04:57 PM, Andrew Coppin wrote: If you think that sounds silly, ask some random person (not a computer programmer, just some random human) how find the sum of a list of numbers. My reply: to sum 10 numbers, sum 9 numbers, then account for the 10th. More at:

Re: [Haskell-cafe] malicious JS on haskell site

2010-09-09 Thread Albert Y. C. Lai
On 10-09-09 05:30 PM, Keith Sheppard wrote: Maybe malicious isn't the right word but there is a JS based web counter on http://www.haskell.org/complex/why_does_haskell_matter.html which likes to show pop up adverts. They must have switched over from counting visitors to showing adverts at some

Re: [Haskell-cafe] ANNOUNCE: Haddock version 2.8.0

2010-09-04 Thread Albert Y. C. Lai
On 10-09-04 01:31 AM, John Millikin wrote: It's not correct. Here's the exact same XHTML document (verify by viewing the source), served with different mimetypes: http://ianen.org/temp/inline-svg.html http://ianen.org/temp/inline-svg.xhtml This relies on xhtml+svg. While it is in the xhtml

Re: [Haskell-cafe] ANNOUNCE: Haddock version 2.8.0

2010-09-04 Thread Albert Y. C. Lai
On 10-09-04 05:46 PM, Jeremy Shaw wrote: Mark suggested that it was easier to achieve multi-browser compatibility using xhtml instead of html, but I am quite certain he is mistaken. There are really three different rendering modes found in browsers: 1. standards mode 2. quirks mode 3.

Re: [Haskell-cafe] Unnecessarily strict implementations

2010-09-04 Thread Albert Y. C. Lai
On 10-09-03 06:11 AM, Henning Thielemann wrote: Yes, something this way. () suggests a notion of magnitude for me, which some orderings do not have. Like for example -1000 has a larger magnitude than -0.0001, therefore you also reject the common ordering -1000 -0.0001?

Re: [Haskell-cafe] ANNOUNCE: Haddock version 2.8.0

2010-09-03 Thread Albert Y. C. Lai
On 10-09-02 09:57 PM, John Millikin wrote: Is there any particular reason you're using XHTML instead of HTML? You're using a transitional doctype, invalid IDs, and the .html file extension -- in short, HTML with an incorrect doctype. The markup doesn't even validate. [...] XHTML is supported

Re: [Haskell-cafe] Unnecessarily strict implementations

2010-09-02 Thread Albert Y. C. Lai
On 10-09-02 12:10 PM, Stephen Sinclair wrote: Sorry to go a bit off topic, but I find it funny that I never really noticed you could perform less-than or greater-than comparisons on Bool values. What's the semantic reasoning behind allowing relative comparisons on booleans? In what context

<    1   2   3   4   >