Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Glasgow Haskell Compiler
GHC
Commits
c7addbef
Commit
c7addbef
authored
May 07, 2007
by
Simon Marlow
Browse files
FIX:
#1253
(Can't use non-layout at top level)
parent
35cb95c2
Changes
1
Hide whitespace changes
Inline
Side-by-side
compiler/parser/Parser.y.pp
View file @
c7addbef
...
...
@@ -361,10 +361,10 @@ module :: { Located (HsModule RdrName) }
{% fileSrcSpan >>= \ loc -> case $1 of { (opt, info, doc) ->
return (L loc (HsModule (Just $3) $5 (fst $7) (snd $7) $4
opt info doc) )}
}
|
missing_module_keyword
top
close
|
body2
{% fileSrcSpan >>= \ loc ->
return (L loc (HsModule Nothing Nothing
(fst $
2
) (snd $
2
) Nothing Nothing emptyHaddockModInfo
(fst $
1
) (snd $
1
) Nothing Nothing emptyHaddockModInfo
Nothing)) }
optdoc
::
{ (Maybe String, HaddockModInfo RdrName, Maybe (HsDoc RdrName)) }
...
...
@@ -385,6 +385,10 @@ body :: { ([LImportDecl RdrName], [LHsDecl RdrName]) }
:
'{'
top
'}'
{ $2 }
|
vocurly
top
close
{ $2 }
body2
::
{ ([LImportDecl RdrName], [LHsDecl RdrName]) }
:
'{'
top
'}'
{ $2 }
|
missing_module_keyword
top
close
{ $2 }
top
::
{ ([LImportDecl RdrName], [LHsDecl RdrName]) }
:
importdecls
{ (reverse $1,[]) }
|
importdecls
';'
cvtopdecls
{ (reverse $1,$3) }
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment