GHC 6.13 doesn't support Haskell 2010's DoAndIfThenElse feature.
GHC doesn't accept DoAndIfThenElse feature's sample code.
foo :: Monad m => Bool -> m Int
foo x = do
if x then
return 1
else
return 2
This code causes parse error.
Prelude> :load Test
[1 of 1] Compiling Main ( Test.hs, interpreted )
Test.hs:5:4: parse error (possibly incorrect indentation)
Failed, modules loaded: none.
Now, GHC support Haskell 2010 in HEAD ( #4098 (closed) ). So, GHC must accept above program.
See also: #2259 (closed)
Trac metadata
Trac field | Value |
---|---|
Version | 6.13 |
Type | Bug |
TypeOfFailure | OtherFailure |
Priority | normal |
Resolution | Unresolved |
Component | Compiler (Parser) |
Test case | |
Differential revisions | |
BlockedBy | |
Related | |
Blocking | |
CC | shelarcy@gmail.com |
Operating system | |
Architecture |