mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-04-09 04:59:31 -06:00
one general case in dealing with backslash in latex lexing is enough
This commit is contained in:
@@ -59,7 +59,6 @@ unlexCode s = case s of
|
||||
lexLatexCode :: String -> [String]
|
||||
lexLatexCode = restoreBackslash . lexCode where --- quick hack: postprocess Haskell's lex
|
||||
restoreBackslash ws = case ws of
|
||||
"\\":"\\":ww -> "\\\\":restoreBackslash ww
|
||||
"\\":w:ww -> ("\\" ++ w) : restoreBackslash ww
|
||||
w:ww -> w:restoreBackslash ww
|
||||
_ -> ws
|
||||
|
||||
Reference in New Issue
Block a user