parseFromString': reset stateLastStrPos to Nothing before parse.
This commit is contained in:
parent
1dec5bacaa
commit
b446c6c448
1 changed files with 1 additions and 0 deletions
|
@ -462,6 +462,7 @@ parseFromString' :: (Stream s m Char, IsString s, HasLastStrPosition u)
|
|||
-> ParserT s u m a
|
||||
parseFromString' parser str = do
|
||||
oldLastStrPos <- getLastStrPos <$> getState
|
||||
updateState $ setLastStrPos Nothing
|
||||
res <- parseFromString parser str
|
||||
updateState $ setLastStrPos oldLastStrPos
|
||||
return res
|
||||
|
|
Loading…
Add table
Reference in a new issue