@@ -445,22 +445,22 @@ inlineCommand :: PandocMonad m => LP m Inlines
445445inlineCommand = try $ do
446446 (name, raw') <- withRaw anyControlSeq
447447 guard $ name /= "begin" && name /= "end"
448− exts <- getOption readerExtensions
449448 star <- option "" (string "*")
450449 let name' = name ++ star
451450 let raw = do
451+ guard $ not (isBlockCommand name)
452452 rawargs <- withRaw
453− (skipangles *> skipopts *> option "" dimenarg *> many braced)
453+ (skipangles *> skipopts *> option "" dimenarg *> many braced)
454454 let rawcommand = raw' ++ star ++ snd rawargs
455455 transformed <- applyMacros' rawcommand
456+ exts <- getOption readerExtensions
456457 if transformed /= rawcommand
457458 then parseFromString inlines transformed
458459 else if extensionEnabled Ext_raw_tex exts
459460 then return $ rawInline "latex" rawcommand
460461 else ignore rawcommand
461− (lookupListDefault mzero [name',name] inlineCommands <*
462+ (lookupListDefault raw [name',name] inlineCommands <*
462463 optional (try (string "{}")))
463− <|> (guard (not (isBlockCommand name)) >> raw)
464464
465465unlessParseRaw :: PandocMonad m => LP m ()
466466unlessParseRaw = getOption readerExtensions >>=
@@ -508,7 +508,6 @@ inlineCommands = M.fromList $
508508 , ("sim", lit "~")
509509 , ("label", unlessParseRaw >> (inBrackets <$> tok))
510510 , ("ref", unlessParseRaw >> (inBrackets <$> tok))
511− , ("noindent", unlessParseRaw >> ignore "noindent")
512511 , ("textgreek", tok)
513512 , ("sep", lit ",")
514513 , ("cref", unlessParseRaw >> (inBrackets <$> tok)) -- from cleveref.sty