LaTeX writer: Update \lstinline delimiters. (#4369)

Don't delimit \lstinline with characters that are normally escaped.

Follow-up to #4111, #4271.
This commit is contained in:
Tim Parenti 2018-04-26 15:41:15 -04:00 committed by John MacFarlane
parent 1494b20bb4
commit 9472811694

View file

@ -1036,7 +1036,7 @@ inlineToLaTeX (Code (_,classes,_) str) = do
Nothing -> ""
inNote <- gets stInNote
when inNote $ modify $ \s -> s{ stVerbInNote = True }
let chr = case "!\"&'()*,-./:;?@_" \\ str of
let chr = case "!\"'()*,-./:;?@" \\ str of
(c:_) -> c
[] -> '!'
let str' = escapeStringUsing (backslashEscapes "\\{}%~_&") str