Hugs, but I still get
Prelude> (1.0 -0.6)
0.40191
so there appears to be a double bug in Hugs.
>>Try the following expression:
>>
>> ? 0.4 > 1.0 - 0.6
>>True
>
>This isn't really a bug - it simply reflects the fact that fl
The www file GHC 2.04 bugs and workarounds
has the section
--
Compiling prelude libraries on x86 machines
...
... register was spilled
The solution is ...
make EXTRA_HC_OPTS=-monly-2-regs
panic! (the `impossible' happened):
deListComp:LetQual
Please report it as a compiler bug to [EMAIL PROTECTED]
-
Here is the offending expression:
[(u',e) | (u',_) <- s, let (b, e) = match u u', b]
Thanks.
Mircea
panic! (the `impossible' happened):
tfun
Please report it as a compiler bug to [EMAIL PROTECTED]
---
It comes from:
let r = read::(String -> Int) rel
Mircea
The following program gives errors with GHC-4.01:
data Def f = String := f String
I had to put parantheses around "f String":
data Def f = String := (f String)
I think this is a bug; Hugs and HBC accept it.
Koen.
--
Koen Claessen,
[EMAIL PROTECTED],
http://www.cs.chalmer
When ghc is invoked as, say,
ghc somedirectory/mymodule.hs
it seems to assume the directory where it is invoked as the
current working directory, and in particular, it searches
for .hi files in that directory.
Now, one could argue that the desirable behaviour is to
assume `somedirectory' as
> When ghc is invoked as, say,
>
> ghc somedirectory/mymodule.hs
>
> it seems to assume the directory where it is invoked as the
> current working directory, and in particular, it searches
> for .hi files in that directory.
>
> Now, one could argue that the desirable behaviour is to
> assum
PROTECTED]'; [EMAIL PROTECTED]
| Subject: RE: A bug, or not a bug...
|
|
| > When ghc is invoked as, say,
| >
| > ghc somedirectory/mymodule.hs
| >
| > it seems to assume the directory where it is invoked as the
| > current working directory, and in particular, it searches
|
Hi guys.
The compiler told me to report a bug so that's what I'm doing. I ran the
following command:
ghc-4.04 -o ghcnewperms3 -O2 -fvia-C -O2-for-C -fusagesp Newperms3.hs
(NB it's not patchlevel 1)
from that I got the following:
panic! (the `impossible' happened):
The function substPS causes a segmentation fault if both more than one match
exists and the global option 'g' is given.
system: ghc 4.04pl1, linux 2.2.10, glibc 2.1
thanks,
k
--
There was a writer in 'Life' magazine ... who claimed that rabbits have
no memory, which is one of their defensiv
Dear all,
I would like to report a bug in ghc-2.02.
In ghc-0.29 and ghc-2.01 the program attached below
compiles fine. The 2.02 version of ghc fails.
Is there any chance this bug will be fixed in near future?
Regards,
Marc van Dongen
sible' happened):
Unexpected Dict or ForAll in occurCheck
Please report it as a compiler bug to [EMAIL PROTECTED]
*
Whereas
> module A( B ) where
> data B = C a
compiles fine. Is this valid Haskell?
Regards,
Marc van Dongen
[EMAIL PROTECTED]
Mircea Draghicescu <[EMAIL PROTECTED]> writes:
>
> panic! (the `impossible' happened):
> deListComp:LetQual
>
> Please report it as a compiler bug to [EMAIL PROTECTED]
>
> -
> Here is the offending expressio
Mircea Draghicescu writes:
>
> panic! (the `impossible' happened):
> tfun
>
...
> It comes from:
>
> let r = read::(String -> Int) rel
>
Thanks for reporting the bug; it is caused by indecision in the
compiler as to who should catch th
Yousry Abdallah <[EMAIL PROTECTED]> writes:
Try the following expression:
? 0.4 > 1.0 - 0.6
True
This isn't really a bug - it simply reflects the fact that floating
point calculations are approximate. If you are using floating point
(in any language), yo
is a compiler bug; please report it to
[EMAIL PROTECTED]
Fail: "coreSyn/CoreUtils.lhs", line 122: pattern-matching failed in case
*** Error code 1
make: Fatal error: Command failed for target `ModuleGA.o'
If it's any help, I've enclosed the code -- it's a bit scrap
Hi,
While I was constructing an example for ghc-users, I created the following
program which crashed ghc-2.03.
> module Tmp( g ) where
> data AB p q = A
> | B p q
> g :: (Ord p,Ord q) => (AB p q) -> Bool
> g (B _ _)
> = g A
tmp.lhs:6:
Warning: Possibly incomplete patter
I would like to report the following bug in ghc-2.04.
Profiling and optimizing with -O2 (I have not and will
not try -O) leads to errors like this at link-time:
CC_mkZubalancedZ92Z92Z92Zq_struct Blah1.o
CC_DICTs_struct Blah2.o
CC_mkZubalancedZ92Zq_struct Blah3.o
Hi there,
With ghc-2.04 I can successfully compile the following:
> module Buggy( buggy ) where
> data L a = L [a]
> class (Eq a,Ord a,Num a,Read a,Show a) => Class a where
> method :: a -> Bool
> instance (Class a) => Class (L a) where
> method (L as) = True
> instance (Class a) => Eq (L
If my memory serves me right, I haven't seen this one in ghc-2.03:
*** Pattern-matching error within GHC!
This is a compiler bug; please report it to [EMAIL PROTECTED]
Fail: "typecheck/Unify.lhs", line 60: incomplete pattern(s) to match in function
"unifyTauTyL
Hi there,
ghc-2.0498, complains about list-comprehensions
when compiling the following. There's probably some
code-transformation going on here.
> module Strange( strange ) where
> strange :: (a,a,a) -> a
> strange triple
> | (first triple) == (fst triple) = first triple
> first
Compiling the code fragment appended at the end of this
message, ghc-2.03 fails with the following output:
Glasgow Haskell Compiler, version 2.03, for Haskell 1.4
panic! (the `impossible' happened):
tcLookupTyVar:a_r6v
Please report it as a compiler bug to [EMAIL PROT
BUG FOUND
I found a compiler bug in 'ghc', it came up as follows: forgetting a
definition, e.g. 'atMost', in a signature, but still keeping a default method
for 'atMost' should produce something like
TestADT.lhs:56: Value not in scope: `atMost'
But wit
Hello,
concerning my previous mail:
during compilation with the binary installed version of
ghc-2.07 for Solaris, I got the following message:
---
*** Pattern-matching error within GHC!
This is a compiler bug; please
; during compilation with the binary installed version of
> ghc-2.07 for Solaris, I got the following message:
> ---
> *** Pattern-matching error within GHC!
>
> This is a compiler bug; please report it to [EMA
Hi there,
When compiling with 2.0899,
I get the following error at linking stage:
Undefined first referenced
symbol in file
getBufferMode /usr/local/ghc-2.09/lib/libHS.a(IOHandle__131.o)
Main_main_closure
Hi there,
I would like to report the following Happy bug.
With rules of the form:
> This :: { Type }
> This: Is A Rule{ let a = 1
> b = 2
> in $1 }
Hap
Dear all,
While compiling some stuff I came across the following:
compiling with -O did failed without any error message
at all.
compiling with -O2 succeeded
?
Any idea what could have caused it? I can tell you how to
reproduce this if wanted.
Regards,
Marc
Hi there,
One of my programs caused a:
Entered Forward_Ref 7f0928: Should never occur!
ghc 2.09 profiled with -O2.
This happened afeter 180 second run-time so it's
probably very difficult to isolate the source of
the problem. Let me know if more information is
needed.
A previous run with di
The following won't compile under 3.00
> data Blah = Blah
> type Tuple = (Blah,Int)
> instance Show Tuple where
> showsPrec _ _ _
> = error []
No instance for: `Show Blah'
arising from use of `PrelBase.$mshowList', at tmp.lhs:8
I know that instances of classes shouldn't be ty
While compiling some stuff with 3.00 which normally compiles with
2.10, I came across the following:
panic! (the `impossible' happened):
ERROR: can't generate code for polymorphic case probably a mis-use of `seq' or
`par';
the User's Guide
Hi there,
In ghc-3.02 the following program compiles fine.
> module Main( main ) where
> f :: String -> Int
> f "=<" = 0
> f "=" = 0
> g :: [Char] -> Int
> g ['=','<'] = 0
> g ['='] = 0
> main = return ()
However, for ``f'' the following is reported.
tmp.lhs:4:
Pattern match(es) a
Lenart was right.
I am sorry, indeed, toZ :: Integral a => a -> Z
toZ = toInteger
helps. I recalled, exactly this was the initial bug program.
But sorry, probably, i had confused something.
Still, why moving toZ = toInteger :: Integral a => a -> Z
to an
Hi there,
I can't see why the following will not compile with 3.02
> module Main( main ) where
> data A a = A (a,a)
> instance (Show a,Ord a) => Num (a,a) where
> (+) a a' = a
> instance (Show a,Ord a) => Eq (A a) where
> (==) a a' = True
> instance Show (A String) where
> showsPrec
). Hugs accepts the same program, no complaints. Iz GHC bug?
--Jeff
Hi,
I have been doing probability theory tests. One of them involved the so
called "secretary problem". Here is my code:
>>>
module Main where
import Random
import List
import IO
type Process = [Integer] -> Bool
simulate :: Int -> Integer -> Process -> IO Double
simulate n m proc =
do tries
I was browsing through the source for Semaphore.lhs when I noticed a bug
in the implementation for waitQSemN. If I understand the workings and
semantics correctly, the value of 'avail' specifies how many resources
are available and the value of 'sz' specifies the number of re
a Def f = String := f String
>
> I had to put parantheses around "f String":
>
> data Def f = String := (f String)
>
> I think this is a bug; Hugs and HBC accept it.
>
> Koen.
>
> --
> Koen Claessen,
> [EMAIL PROTECTED],
> http://www.cs.chalmers.se/~koen,
> Chalmers University of Technology.
>
Hello!
I got an error compiling my program with ghc-4.02 and ghc-4.03 (-O option)
(files error#ghc-4.02-O and error#ghc-4.03-O)
I tried compiling with ghc-4.03 without the -O option, but it did'nt help
(file error#ghc-4.03)
I would be glad if You could give me a hint how to compile it anyway.
I s
Here one of my favourite bugs in larger projects (IIRC, this
has partly been reported by me in the "Importing, hiding, and
exporting" thread):
-- A.hs -
module A where
data Foo = Foo -- Typo! Forgot "deriving Show"
-- B.hs --
The following patch should fix 4.02's GC bug. I'll put up fixed
distributions as soon as possible.
diff -c -c -r1.30 GC.c
*** GC.c1999/02/11 17:40:26 1.30
--- GC.c1999/02/15 14:21:50
***
*** 1932,1941
scavenge_mutable_list(gener
Hi,
I have found a bug with mkdependHS. The bug which I am reporting is present
in ghc 2.07, but I believe that it has been around for sometime. It is by no
means a serious bug, but worth reporting. I have included below a makefile,
the two Haskell modules and the make error which demonstrate
Ian noted the following bug:
> * `foreign' seems to have become a keyword ! My program uses it as a
> variable/function name and I had to rename it to avoid a parse error.
> I couldn't find anything about it in my documentation.
As Michael noted, this is a consequence of
ray Int
When checking declaration:
foreign import _ccall "c_test" h_test :: ByteArray Int -> IO ()
Compilation had errors
make: *** [Main.o] Error 1
---
My configuration is:
(~/project/bug 88) uname -sr
SunOS 5.6
(~/project/bug 89) dmesg | grep SUNW
cpu0:
> Hi guys.
>
> The compiler told me to report a bug so that's what I'm doing. I ran the
> following command:
>
> ghc-4.04 -o ghcnewperms3 -O2 -fvia-C -O2-for-C -fusagesp Newperms3.hs
>
> (NB it's not patchlevel 1)
> from that I got the followi
This program:
> import Numeric
> main = putStrLn (showEFloat Nothing (0.5::Float) [])
Gives an answer of 5.0e0 for the current build of GHC (4.05),
on my NT box. It comes from test numeric/num008.hs.
(It looks like the test has been mastered incorrectly)
Andy Gill
Hi,
I have (maybe temporarily) given up on H/Direct. The system
just seems way too heavyweight to use for the simple
application I had in mind (let alone to install everything).
Therefore, I tried GreenCard. The compiler works fine, but
when I compile the c-code, it complains about "GreenCard.h"
| > module A( B ) where
|
| > data B = C a
This isn't legal Haskell: data constructors can't mention
type variables not bound on the left hand side. This would be legal
> data B a = C a
But it still shouldn't crash the compiler!
Thanks for the bug report
Simon
> {
> happyError :: Int -> [Token] -> a
> happyError i'' _
> = error errstr
> where errstr = "This code fragment forces Happy to return with" ++
> "the following error message:\n\n" ++
> "Fail: Lexical Error: No closing '}' in code segment\n\n" ++
>
Fri, 30 May 1997 12:14:47 +0100 (BST)
| If my memory serves me right, I haven't seen this one in ghc-2.03:
|
| *** Pattern-matching error within GHC!
| This is a compiler bug; please report it to [EMAIL PROTECTED]
| k.
| Fail: "typecheck/Unify.lhs", line 60: incomplete patt
Marc,
GHC 2.04 correctly says
Main.hs:17: Ambiguous overloading
arising from use of `g' at Main.hs:23
`PrelBase.Ord' `p{-a17v-}'
When checking signature(s) for: `g'
| From: Marc van Dongen <[EMAIL PROTECTED]>
| Date: Sat, 31 May 1997 14:35:40 +0100 (BST
Marc van Dongen writes:
> Hi,
>
> While I was constructing an example for ghc-users, I created the following
> program which crashed ghc-2.03.
>
> > module Tmp( g ) where
>
> > data AB p q = A
> > | B p q
>
> > g :: (Ord p,Ord q) => (AB p q) -> Bool
> > g (B _ _)
> > = g A
>
>
Thanks, misleading error message this - the pattern guard extension
allows you to write qualifiers a la list comprehensions on the
left-hand side.
The front-end simply re-uses the implementation for list
comprehensions to do this, hence the error messages may still be a bit
skewed toward list c
> > > module Strange( strange ) where
> >
> > > strange :: (a,a,a) -> a
> > > strange triple
> > > | (first triple) == (fst triple) = first triple
> >
> > > first :: (a,b,c) -> a
> > > first (a,b,c)
> > > = a
> >
> > Stange.lhs:5: Couldn't match the type
> >`PrelTup.(,,) t
Marc you are outstanding at winkling out these bugs.
This is an erroneous program because 0 doesn't have type (forall a.a),
but it should not crash the compiler.
I've fixed it in 2.04.
Simon
| From: Marc van Dongen <[EMAIL PROTECTED]>
| Date: Thu, 29 May 1997 22:38:32 +0100 (BST)
| Compiling t
When compiling a (rather long) file with GHC 2.05, compiled with GHC
0.29 on a Linux box, I got the following error:
ghc -H16M -c Basic.hs
*** Pattern-matching error within GHC!
This is a compiler bug; please report it to [EMAIL PROTECTED]
Fail: "basicTypes/Id.lhs", line 990:
Barry O'Sullivan <[EMAIL PROTECTED]> writes:
> Essentially, mkdependHS always picks-up an import statement even if the
> import is commented as shown in My_Module.hs below. Commenting imports in
> this manner will cause mkdependHS to crash with the error I have included.
Yes, mkdependHS doesn't
Thanks for the fine bug report. It'll be fixed in the next release.
Simon
> I found a compiler bug in 'ghc', it came up as follows: forgetting a
> definition, e.g. 'atMost', in a signature, but still keeping a default method
> for 'atMost' should
Marc van Dongen= <[EMAIL PROTECTED]> writes:
> I would like to report the following Happy bug.
> With rules of the form:
>
> > This :: { Type }
> > This: Is A Rule{ let a = 1
> >
Hi!
I tried installing GHC 2.10 (Jan 7 version) and get this:
spitfire% make in-place
make config-pkgs bindir=`pwd`/bin/sparc-sun-solaris2/ghc-2.10
libdir=`pwd`/lib/sparc-sun-solaris2 datadir=`pwd`/share/ghc-2.10
Configuring ghc, version 2.10, on sparc-sun-solaris2 ...
Creating a configured v
Hello!
Happy-1.3 creates code which isn't compilable due to erroneous
indentation, using the attached grammar. After correcting the
indentation, it compiles.
bye.
SOF:
> install-sh is the fallback script used if the configure script is
> unable to find an OK looking `install' somewhere along your PATH.
Oops, I confess to not knowing this. Configure doesn't seem to moan too
loudly about the lack of an "install", so I assumed that it was The
Real Program.
Marc van Dongen= <[EMAIL PROTECTED]> writes:
> While compiling some stuff I came across the following:
> compiling with -O did failed without any error message
> at all.
> compiling with -O2 succeeded
>
> ?
>
> Any idea what could have caused it? I can tell you how to
> reproduce this if wa
Marc van Dongen= <[EMAIL PROTECTED]> writes:
> One of my programs caused a:
>
> Entered Forward_Ref 7f0928: Should never occur!
We've heard of this one before, but haven't actually been able to
reproduce it. Anyway, the upshot is that we're rewriting the
profiling support for the new run-time
Simon L Peyton Jones <[EMAIL PROTECTED]> writes:
> > So are types not longer allowed in instance declarations?
>
> Yes they're allowed, but it's just as if you'd written the
> expanded type. Any two instance decls that don't overlap are
> allowed. You can write
>
> instance C (Blah,Int
#{-3e-}
-> GHC.Int#{-3e-}
-> b_trKC
-> PolyParse.HappyState{-rq9-} b_trKC c_trKD
-> [PolyParse.HappyState{-rq9-} b_trKC c_trKD]
-> c_trKD
Please report it as a compiler bug to [EMAIL PROTECTED]
Needless to say that I h
Mark says:
> > data Blah = Blah
> > type Tuple = (Blah,Int)
>
> > instance Show Tuple where
> > showsPrec _ _ _
> > = error []
>
> No instance for: `Show Blah'
> arising from use of `PrelBase.$mshowList', at tmp.lhs:8
>
> I know that instances of classes shouldn't be types,
> Did you do 'make install' in ghc, instead of using the binary
> distribution?
I did make install from a build from source, yes, not least as there was
no binary distrib. available at that point. ;-)
> Hard links are a pain for several reasons - if you install a new ghc
> over the existing on
> From [EMAIL PROTECTED] Fri Nov 28 11:48:59
1997
> This is another file missing from the source distribution. The new
> one is now up, and it contains all the necessary files.
Can you put this up as a patch, too?
> It does for me - but the sense of the link is reversed (i.e. now ghc
> point
Marc van Dongen wrote:
> [ program omitted ]
> However, for ``f'' the following is reported.
>
> tmp.lhs:4:
> Pattern match(es) are overlapped in the definition of function `f'
> "=" = ...
>
> There are no complaints for defin
rdness: Dictionary.insert{-r7l-}
importDecl wierdness: Dictionary.Dictionary{-r7a-}
panic! (the `impossible' happened):
tcLookupClass Dictionary.Dictionary{-r7a-}
Please report it as a compiler bug to [EMAIL PROTECTED]
module Dictionary where
data SearchResult a = Found a | Fail
class (Eq
Hello,
I tried to rebuild ghc-4.00-pre2 with itself and ran into a bug:
---
...
ghc-4.00 -cpp -fglasgow-exts -Rghc-timing -I. -IcodeGen -InativeGen -Iparser
High again,
make boot succeeded, make all stops with
[..]
IdUtils.lhs:16: Module `PrimOp' does not export `primOpInfo'
IdUtils.lhs:16: Module `PrimOp' does not export `PrimOpInfo(..)'
Compilation had errors
make[2]: *** [basicTypes/IdUtils.o] Error 1
make[1]: *** [all] Error 1
make: *** [a
The following bug occurred while compiling GHC-4.00 on a Linux
platform, using ghc-3.03, gcc-2.7.3.2
Thanks
Ed
-
ghc-3.03 -cpp -fglasgow-exts -Rghc-timing -I. -IcodeGen -InativeGen
-Iparser
Hi,
There is a bug in module Readline. The string that function `readline'
returns
is deleted before you can add it to the history. So getting entries from
the
history table often results in strings that wouldn`t occur in your
wildest dreams.
This never happened under Solaris, but a
> Lenart was right.
> I am sorry, indeed, toZ :: Integral a => a -> Z
> toZ = toInteger
> helps. I recalled, exactly this was the initial bug program.
> But sorry, probably, i had confused something.
>
>
> Still, why moving toZ = toIn
Hi there,
While compiling some stuff with 4.00 I get the following
output before compilation stops.
[snip]
GNU CPP version 2.7.2 (sparc)
#include "..." search starts here:
#include <...> search starts here:
.
/usr/local/ghc-4.00/lib/ghc-4.00/includes
/usr/local/ghc-4.00/lib/ghc-4.00/include
Yes, Jeff Lewis demonstrated this bug a while back.
It's fixed in the current sources (4.x) sources.
If it's important then I guess we can retro-fit 3.0x,
but we're planning to put out a (ha!) reliable 4.01 at the
end of Nov.
Thanks for a fine report
Simon
> -Original M
I've mailed to hugs-bugs, but their mailing list appears to be acting up.
Really this is a Hugs/GHC difference with the Word library.
In GHC Word64 is an instance of Num, in Hugs (as of Hugs-98) it is
not.
- Byron
Jeff found a nice bug here. GHC tries not to import too many
instance decls because then it has to import the types they mention,
and that means more instance decls and so on.
But here, an instance decl used a type synonym, and did so in the
interface file; but in the importing module that
Hi,
I enclose a small program that causes ghc 4.01 to say "panic! (the
`impossible' happened)". I also supply the output from ghc -v.
Regards,
Thomas Hallgren
module GhcBug where
data E = B { a,b,c,d,e,f::Bool }
bug x =
case x of
-- alt 1 and alt 2 should be e
> Michael Hobbs [mailto:[EMAIL PROTECTED]] writes:
>
> I was browsing through the source for Semaphore.lhs when I
> noticed a bug in the implementation for waitQSemN. If I understand
> the workings and semantics correctly, the value of 'avail' specifies
> how
Hi,
there's a little bug in randomIvalInteger of Random.lhs (ghc-4.02):
| otherwise = case (f n 1 rng) of (v, rng') -> (fromInteger (v `mod` (k+1)),
rng')
where
k = h - l + 1
should be something like
| otherwise = case (f n 1 rng) of (v, rng') -> (fr
CVS Snapshot Bug?
Please let me know if you need more information.
Regards,
Richard
nauru{reidrm}2135: setenv CVSROOT :pserver:[EMAIL PROTECTED]:/cvs
nauru{reidrm}2136: setenv CVS_RSH ssh
nauru{reidrm}2137: cvs checkout fpconfig
[snip]
nauru{reidrm}2138
Andreas
Thanks for a fine report. This one must have been lurking
for ages! Fixed in the CVS tree. A one-line change in deSugar/DsHsSyn.lhs
Simon
[For others: this innocuous program was being desugared wrongly.]
erroR :: Int
erroR = n where
(n+1,_) = (5,2)
Hi there,
The following program (ghc-4.02):
> f :: [Int] -> Int
> f (i:is) | trace "0" False = error []
> f is | trace "1" False = error []
> f is = f $ tail is
> main = putStr $ show $ f [0]
Outputs:
1
Fail: Prelude.tail: empty list
wheras it should have output:
0
1
Fail: Prelude.ta
Compiling (under ghc 3.02) and running the following:
--
main = seq (putStrLn "xpto") (print "bug")
-
produces:
xpto
Segmentation fault caught, address = 8049a14
Aborted
(Hugs 1.4 p
Is this a bug with ghc-4.04 or just a "feature" of Haskell 98 that I was
unaware of? I get a parse error with the following code:
data Point = Pt {pointx, pointy :: Float}
abs (Pt {pointx, pointy}) = sqrt (pointx*pointx + pointy*pointy)
It doesn't like the `,' on the second
Simon Peyton-Jones wrote:
> There's something very mysterious going on here. The
> booted compiler does something different to the non-booted one!
> (The latter works ok.)
:-}
> [...] This isn't really holding you up now, right?
No, it doesn't: "grep Show *.hi" helps...
Ciao,
Sven
--
Sve
en Panne
> Sent: Tuesday, August 17, 1999 8:27 PM
> To: GHC Bugs
> Subject: Instance bug
>
>
> Here one of my favourite bugs in larger projects (IIRC, this
> has partly been reported by me in the "Importing, hiding, and
> exporting" thread):
>
> -- A.hs --
: Friday, August 20, 1999 12:55 PM
> To: 'Sven Panne'; GHC Bugs
> Subject: RE: Instance bug
>
>
> There's something very mysterious going on here. The
> booted compiler does something different to the non-booted one!
> (The latter works ok.)
>
> Will investi
This program:
--
--import Trace
import IOExts
import Monad
import System
newtype State s a = State { runState :: s -> (a,s) }
instance Monad (State s) where
return v = State (\ s -> (v,s))
p >>= f = State (\ s
I must admit that I don't fully understand the new offside rule
anymore, but the following is probably a bug in ghc-4.04 (note that
putStrLn is in the same column as the second occurrence of greetings):
-- Foo.hs ---
main = greetings
where greetings =
put
Alex Ferguson <[EMAIL PROTECTED]> writes:
> > Did you do 'make install' in ghc, instead of using the binary
> > distribution?
>
> I did make install from a build from source, yes, not least as there was
> no binary distrib. available at that point. ;-)
R
Just a minor thing in 2.08, install copies the driver to bin/ghc and sets
a symlink from ghc-2.08 to ghc rather than the other way round so it overwrites
the old copy...
94 -rwxr-xr-x 1 jpc195903 Oct 9 17:56 ghc
1 lrwxrwxrwx 1 jpc13 Oct 2 17:01 ghc-2.07 -> ghc
1
Marc van Dongen= <[EMAIL PROTECTED]> writes:
> When compiling with 2.0899,
Gee, I really must fix that...
> I get the following error at linking stage:
>
> Undefined first referenced
> symbol in file
> getBufferMode
Alex Ferguson <[EMAIL PROTECTED]> writes:
> > It does for me - but the sense of the link is reversed (i.e. now ghc
> > points to ghc-2.09, which is the real driver).
>
> Odd. It doesn't seem to do this at all for me. There's no "ghc-2.09",
> and "ghc" isn't a link. I can't see where in the ma
(I'm using GHC 4.04 patchlevel 1...)
Suppose I have a type involving higher kinds such as
data H f a = H (f a)
and now suppose I want to define equality on this type.
I *cannot* say
instance Eq (f a) => Eq (H f a) where
H x == H y = x == y
because I get an error message
Illegal con
Malcolm writes:
> Ian noted the following bug:
>
> > * `foreign' seems to have become a keyword ! My program
> uses it as a
> > variable/function name and I had to rename it to avoid a
> parse error.
> > I couldn't find anything about it in my documen
Me:
> > However, it is definitely wrong for 'foreign' to be treated as a
> > keyword. Instead, it is a special identifier
Simon:
> Tricky, at least in LALR(1).
Yes, you are right of course. Backtracking parser combinators had me
blinded to the sad realities of the world. :-)
> There are stan
1 - 100 of 308 matches
Mail list logo