[GHC] #8081: let form in do block requires in?
GHC
ghc-devs at haskell.org
Mon Jul 22 12:40:34 CEST 2013
#8081: let form in do block requires in?
----------------------------------------------+----------------------------
Reporter: dsamperi | Owner:
Type: bug | Status: closed
Priority: normal | Milestone:
Component: Compiler | Version: 7.6.3
Resolution: invalid | Keywords:
Operating System: Linux | Architecture: x86_64
Type of failure: GHC rejects valid program | (amd64)
Test Case: | Difficulty: Unknown
Blocking: | Blocked By:
| Related Tickets:
----------------------------------------------+----------------------------
Changes (by igloo):
* status: new => closed
* resolution: => invalid
Comment:
Thanks for the report. However, the problem isn't that `in` is needed, but
is due to the implicit layout for the `let` not behaving as you expect. If
you use explicit layout for the `let` too then it is accepted:
{{{
do1 = do { let { x = 3.14 } ; return x }
}}}
You can also use implicit layout if you lay the code out differently:
{{{
do1 = do let x = 3.14
return x
}}}
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/8081#comment:1>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list