Skip to content

Commit 473ae42

Browse files
authored
Merge pull request #138 from VanessaCristiny/comment-haskell
Fix on nested_comment in haskell.x
2 parents f2c343b + 4d3c7c7 commit 473ae42

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

examples/haskell.x

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,9 +136,11 @@ nested_comment _ _ = do
136136
Just (c,input) -> do
137137
case chr (fromIntegral c) of
138138
'-' -> do
139+
let temp = input
139140
case alexGetByte input of
140141
Nothing -> err input
141142
Just (125,input) -> go (n-1) input
143+
Just (45, input) -> go n temp
142144
Just (c,input) -> go n input
143145
'\123' -> do
144146
case alexGetByte input of

0 commit comments

Comments
 (0)