diff options
author | John MacFarlane <jgm@berkeley.edu> | 2019-08-26 15:52:25 -0700 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2019-08-26 15:52:25 -0700 |
commit | b446c6c44818b6516905ffd1fd0359c5fe16c64a (patch) | |
tree | 94170ee1d8dfe74eb0e25b402394fcc32b933e1f /src/Text/Pandoc | |
parent | 1dec5bacaa9f5a89615684dc24ee0e67642d0c06 (diff) | |
download | pandoc-b446c6c44818b6516905ffd1fd0359c5fe16c64a.tar.gz |
parseFromString': reset stateLastStrPos to Nothing before parse.
Diffstat (limited to 'src/Text/Pandoc')
-rw-r--r-- | src/Text/Pandoc/Parsing.hs | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/Text/Pandoc/Parsing.hs b/src/Text/Pandoc/Parsing.hs index 959e272a1..a50add362 100644 --- a/src/Text/Pandoc/Parsing.hs +++ b/src/Text/Pandoc/Parsing.hs @@ -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 |