[GHC] #3645: Layout and pragmas
GHC
cvs-ghc at haskell.org
Fri Dec 10 17:59:00 CET 2010
#3645: Layout and pragmas
----------------------------------+-----------------------------------------
Reporter: igloo | Owner:
Type: feature request | Status: new
Priority: normal | Milestone: 7.0.1
Component: Compiler (Parser) | Version: 6.10.4
Keywords: | Testcase:
Blockedby: | Difficulty: Unknown
Os: Unknown/Multiple | Blocking:
Architecture: Unknown/Multiple | Failure: None/Unknown
----------------------------------+-----------------------------------------
Comment(by boris):
Please, review the patch.
The problem was that line
{{{
<0,option_prags> \n { begin bol }
}}}
switched alex state to to ''bol''. If there is space between newline and
"#-}", the previous state is popped in do_bol function and end of pragma
successfully matches in ''option_prags'' state. But without any space the
beginning of "#-}" will be matched in ''bol'' state and the rest will fail
to match.
Perhaps the patch is a little hacky and it is better to modify bol part.
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/3645#comment:5>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the Glasgow-haskell-bugs
mailing list