projects
/
ghc-hetmet.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
[project @ 2004-02-02 10:49:20 by simonmar]
[ghc-hetmet.git]
/
ghc
/
compiler
/
parser
/
Lexer.x
diff --git
a/ghc/compiler/parser/Lexer.x
b/ghc/compiler/parser/Lexer.x
index
05537a9
..
e83bf94
100644
(file)
--- a/
ghc/compiler/parser/Lexer.x
+++ b/
ghc/compiler/parser/Lexer.x
@@
-159,7
+159,9
@@
$white_no_nl+ ;
-- {-# LINE <line> "<file>" #-}
<line_prag2> $digit+ { set_line line_prag2a }
<line_prag2a> \" [$graphic \ ]* \" { set_file line_prag2b }
-- {-# LINE <line> "<file>" #-}
<line_prag2> $digit+ { set_line line_prag2a }
<line_prag2a> \" [$graphic \ ]* \" { set_file line_prag2b }
-<line_prag2b> "#-}" { pop }
+<line_prag2b> "#-}"|"-}" { pop }
+ -- NOTE: accept -} at the end of a LINE pragma, for compatibility
+ -- with older versions of GHC which generated these.
<0,glaexts> {
"{-#" $whitechar* (SPECIALI[SZ]E|speciali[sz]e)
<0,glaexts> {
"{-#" $whitechar* (SPECIALI[SZ]E|speciali[sz]e)