LaTeX reader: allow inline groups starting with \bgroup.

Closes #7953.
This commit is contained in:
John MacFarlane 2022-03-09 17:40:15 -08:00
parent 82d9f5eb8b
commit 581c94913f
3 changed files with 13 additions and 2 deletions

View file

@ -639,9 +639,9 @@ inline = do
"}" -> mzero
_ -> symbolAsString
CtrlSeq _ -> macroDef (rawInline "latex")
<|> inlineGroup
<|> inlineCommand'
<|> inlineEnvironment
<|> inlineGroup
_ -> mzero
inlines :: PandocMonad m => LP m Inlines

11
test/command/7953.md Normal file
View file

@ -0,0 +1,11 @@
```
% pandoc -f latex -t native
{foo\bgroup bar\egroup }
^D
[ Para
[ Span
( "" , [] , [] )
[ Str "foo" , Span ( "" , [] , [] ) [ Str "bar" ] ]
]
]
```

View file

@ -8,5 +8,5 @@
hi
\end{foo}
^D
<p><em>hi</em></p>
<p><span> <em>hi</em> </span></p>
```