GHC non-termination

2006-09-05 Thread Robert Dockins
Hello all, I've discovered that GHC doesn't deal very well with the following program. It appears to diverge when running the following program with 'runghc'. The main compiler can also be persuaded to diverge in a similar fashion. Hugs exhibits correct behavior, ie, it prints hello.

Re: GHC non-termination

2006-09-05 Thread Robert Dockins
- | From: [EMAIL PROTECTED] [mailto:glasgow-haskell-users- | [EMAIL PROTECTED] On Behalf Of Robert Dockins | Sent: 05 September 2006 20:48 | To: glasgow-haskell-users@haskell.org | Subject: GHC non-termination | | Hello all, | | I've discovered that GHC doesn't deal very well with the following

Compile problem on Windows

2006-07-14 Thread Robert Dockins
I posted a message on the libraries list a couple of days ago about a compile problem I'm having. I haven't got any nibbles. Because I now suspect this is a GHC problem, I'm posting here to see it I can get this resolved. Rather than repost the details, allow me to refer you to

Re: Compile problem on Windows

2006-07-14 Thread Robert Dockins
On Jul 14, 2006, at 12:26 PM, Esa Ilari Vuokko wrote: On 7/14/06, Robert Dockins [EMAIL PROTECTED] wrote: I posted a message on the libraries list a couple of days ago about a compile problem I'm having. I haven't got any nibbles. Because I Sorry, it slipped past me. The reason nobody

Re: Understanding directory structure of ghc installation

2006-06-01 Thread Robert Dockins
On Jun 1, 2006, at 6:36 AM, Brian Hulley wrote: Hi - I've just downloaded and installed Edison using Cabal. How did that go for you? You appear to have had some success ;-) I ask because 1.2rc4 has a new build system and I'm interested in your experience. Also, have you tried running

Re: Optimization Destructive Updates

2006-04-14 Thread Robert Dockins
On Apr 14, 2006, at 12:25 PM, Lajos Nagy wrote: I was just musing the other day about the possibility of allowing (efficient and transparent) destructive updates in certain situations. Take the following (giberish) example: f xs = g xs [] where g [] ac = ac g (x1:x2:xs) ac = g

Re: Need help to call ord in Data.Char

2006-03-04 Thread Robert Dockins
On Saturday 04 March 2006 11:03 am, Omar Alvi wrote: Hello, I am new to Haskell(GHC). When i try to call the function ord which is in Data.Char from Prelude prompt. I get the following error. Not in scope ord. Hope to hear from someone soon. From your comments, I assume you're using ghci.

Re: Optimizations for mutable structures?

2005-12-07 Thread Robert Dockins
On Dec 7, 2005, at 12:05 PM, Simon Marlow wrote: On 07 December 2005 16:38, Malcolm Wallace wrote: Simon Marlow [EMAIL PROTECTED] writes: I should have said that if 'acts' blocks, then the transformation is invalid. Well that is exactly what I was assuming when I said that the

Re: explicit signatures and default for integer literals

2005-05-31 Thread robert dockins
Dinko Tenev wrote: First we observe that, g = new . flip zip [0..], so, without the type specification, it has the general type (New [(a, b1)] b, Num b1, Enum b1) = [a] - b, as reported by GHC. Then we infer from (1) g :: (New [(u, v)] w, Num v, Enum v) = [u] - w and (2) instance

GHC as library

2005-05-09 Thread Robert Dockins
://coq.inria.fr/) from Haskell, and being able to get my hands on various things would be really nice (like being able to get at the AST after typechecking, but before conversion to core). Robert Dockins ___ Glasgow-haskell-users mailing list Glasgow

Re: Problem with DB and Char size (2)

2005-01-27 Thread robert dockins
As I haven't found how to force the driver not to strip the byte, and also I don't like to convert data two times, I'd try to send 8 bit strings, but don't know how. Is Word8 a solution? If it is, what is the contstructor?, as w = W8# 1 doesn't compile. I'm weak on low level Haskell. Where do

Re: Newbie question

2005-01-09 Thread Robert Dockins
comments inline... module Main where import IO main = do hSetBuffering stdin LineBuffering words - askForNumbers printWords words map read words putStrLn The sum is foldl (+) 0 words as you noted map read words is a problematic line. The

Re: [Haskell-cafe] Re: Double - CDouble, realToFrac doesn't work

2004-11-05 Thread Robert Dockins
My guess is because irrationals can't be represented on a discrete computer (unless you consider a computaion, the limit of which is the irrational number in question). A single irrational might not just be arbitrarily long, but it may have an _infinite_ length representation! What you have

Re: [Haskell-cafe] Re: Double - CDouble, realToFrac doesn't work

2004-11-05 Thread Robert Dockins
[...] Thus (a-b) is not the same as -(b-a) for IEEE floats! Nor is x*0 equal to 0 for every x; nor does x == y imply f(x) == f(y) for every x, y, f; nor is addition or multiplication associative. There aren't many identities that do hold of floating point numbers. Yes, but they DO hold for

Re: Mutable hash?

2004-10-21 Thread Robert Dockins
There is a hashtable in the IO monad: http://www.haskell.org/ghc/docs/latest/html/libraries/base/Data.HashTable.html I understand there was an important bugfix that went into 6.2.2 for this hashtable implementation, so you'll probably want to make sure to use the latest GHC if you'll be using