More anyLine tweaks: Use incSourceLine.
commitd27dc6a420845ed1b9fd0af96941a546dcd8b98d
authorJohn MacFarlane <fiddlosopher@gmail.com>
dateFri 25 Jan 2013, 17:59 (14 years ago)
parent0801b12
src/Text/Pandoc/Parsing.hs+1−1
@@ -197,7 +197,7 @@ anyLine = do
197197 pos <- getPosition
198198 let (this, rest) = break (=='\n') inp
199199 setInput rest
200− let newpos = setSourceLine (setSourceColumn pos 0) (sourceLine pos + 1)
200+ let newpos = incSourceLine (setSourceColumn pos 0) 1
201201 setPosition newpos
202202 void (char '\n') <|> (guard (not $ null this) >> eof)
203203 return this