@@ -137,14 +137,13 @@ anyLine =
137137 <* updateLastPreCharPos
138138 <* updateLastForbiddenCharPos
139139
140−-- The version Text.Pandoc.Parsing cannot be used, as we need additional parts
141−-- of the state saved and restored.
140+-- | Like @'Text.Pandoc.Parsing'@, but resets the position of the last character
141+-- allowed before emphasised text.
142142parseFromString :: Monad m => OrgParser m a -> String -> OrgParser m a
143143parseFromString parser str' = do
144− oldLastPreCharPos <- orgStateLastPreCharPos <$> getState
145144 updateState $ \s -> s{ orgStateLastPreCharPos = Nothing }
146145 result <- P.parseFromString parser str'
147− updateState $ \s -> s{ orgStateLastPreCharPos = oldLastPreCharPos }
146+ updateState $ \s -> s { orgStateLastPreCharPos = Nothing }
148147 return result
149148
150149-- | Skip one or more tab or space characters.