git.iko.soy/typeable/pandoc
on master help sign in
LaTeX reader: fixed previous commit.
c139a01John MacFarlane
src/Text/Pandoc/Readers/LaTeX.hs+3−3
@@ -286,18 +286,18 @@ rawLaTeXBlock = do
286 lookAhead (try (char '\\' >> letter))
286 lookAhead (try (char '\\' >> letter))
287 -- we don't want to apply newly defined latex macros to their own
287 -- we don't want to apply newly defined latex macros to their own
288 -- definitions:
288 -- definitions:
289− snd <$> rawLaTeXParser (environment <|> macroDef <|> blockCommand) block
289+ snd <$> rawLaTeXParser (environment <|> macroDef <|> blockCommand) blocks
290
290
291rawLaTeXInline :: (PandocMonad m, HasMacros s, HasReaderOptions s)
291rawLaTeXInline :: (PandocMonad m, HasMacros s, HasReaderOptions s)
292 => ParserT String s m String
292 => ParserT String s m String
293rawLaTeXInline = do
293rawLaTeXInline = do
294 lookAhead (try (char '\\' >> letter))
294 lookAhead (try (char '\\' >> letter))
295− snd <$> rawLaTeXParser (inlineEnvironment <|> inlineCommand') inline
295+ snd <$> rawLaTeXParser (inlineEnvironment <|> inlineCommand') inlines
296
296
297inlineCommand :: PandocMonad m => ParserT String ParserState m Inlines
297inlineCommand :: PandocMonad m => ParserT String ParserState m Inlines
298inlineCommand = do
298inlineCommand = do
299 lookAhead (try (char '\\' >> letter))
299 lookAhead (try (char '\\' >> letter))
300− fst <$> rawLaTeXParser (inlineEnvironment <|> inlineCommand') inline
300+ fst <$> rawLaTeXParser (inlineEnvironment <|> inlineCommand') inlines
301
301
302tokenize :: SourceName -> Text -> [Tok]
302tokenize :: SourceName -> Text -> [Tok]
303tokenize sourcename = totoks (initialPos sourcename)
303tokenize sourcename = totoks (initialPos sourcename)