Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Alex D
GHC
Commits
56f147d4
Commit
56f147d4
authored
Apr 21, 2009
by
Simon Marlow
Browse files
FIX #3153: we lost an EOF sentinel in the event of a lexical error
parent
709c9ce0
Changes
1
Hide whitespace changes
Inline
Side-by-side
compiler/main/HeaderInfo.hs
View file @
56f147d4
...
...
@@ -123,8 +123,9 @@ lazyGetToks dflags filename handle = do
_other
->
do
rest
<-
lazyLexBuf
handle
state'
eof
return
(
t
:
rest
)
_
|
not
eof
->
getMore
handle
state
|
otherwise
->
return
[]
|
otherwise
->
return
[
L
(
last_loc
state
)
ITeof
]
-- parser assumes an ITeof sentinel at the end
getMore
::
Handle
->
PState
->
IO
[
Located
Token
]
getMore
handle
state
=
do
-- pprTrace "getMore" (text (show (buffer state))) (return ())
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a 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