mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-04-23 03:32:51 -06:00
A somewhat better solution to the words/UTF-8 problem: do encoding last, but only on what appears to be string literals.
This commit is contained in:
@@ -5,8 +5,7 @@ compactPrint = compactPrintCustom keywordGF (const False)
|
||||
|
||||
compactPrintGFCC = compactPrintCustom (const False) keywordGFCC
|
||||
|
||||
-- FIXME: using words is not safe, since this is run on UTF-8 encoded data.
|
||||
compactPrintCustom pre post = id -- dps . concat . map (spaceIf pre post) . words
|
||||
compactPrintCustom pre post = dps . concat . map (spaceIf pre post) . words
|
||||
|
||||
dps = dropWhile isSpace
|
||||
|
||||
|
||||
Reference in New Issue
Block a user