mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-04-23 11:42:49 -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:
@@ -208,7 +208,7 @@ compileSourceModule opts env@(k,gr,_) mo@(i,mi) = do
|
||||
generateModuleCode :: Options -> FilePath -> SourceModule -> IOE SourceModule
|
||||
generateModuleCode opts file minfo = do
|
||||
let minfo1 = subexpModule minfo
|
||||
out = prGrammar (MGrammar [codeSourceModule encodeUTF8 minfo1])
|
||||
out = codeStringLiterals encodeUTF8 $ prGrammar (MGrammar [minfo1])
|
||||
putPointE Normal opts (" wrote file" +++ file) $ ioeIO $ writeFile file $ out
|
||||
return minfo1
|
||||
|
||||
|
||||
Reference in New Issue
Block a user