diff options
| author | krasimir <krasimir@chalmers.se> | 2010-04-19 09:38:36 +0000 |
|---|---|---|
| committer | krasimir <krasimir@chalmers.se> | 2010-04-19 09:38:36 +0000 |
| commit | 6313244eacf992fb10a5091bee28582e84540809 (patch) | |
| tree | 8208fb18a5e1ab9447bd060cf08a3d78ed0a8c0a /src/compiler/GF/Compile.hs | |
| parent | 8b5827fc892c2f395ae26f1811da2d4cc3b1669d (diff) | |
use the native unicode support from GHC 6.12
Diffstat (limited to 'src/compiler/GF/Compile.hs')
| -rw-r--r-- | src/compiler/GF/Compile.hs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/compiler/GF/Compile.hs b/src/compiler/GF/Compile.hs index a862f85e2..1aebeaf31 100644 --- a/src/compiler/GF/Compile.hs +++ b/src/compiler/GF/Compile.hs @@ -12,7 +12,6 @@ import GF.Compile.Update import GF.Compile.Refresh import GF.Compile.Coding -import GF.Text.UTF8 ---- import GF.Grammar.Grammar import GF.Grammar.Lookup @@ -82,7 +81,7 @@ compileSourceGrammar opts gr@(MGrammar ms) = do -- to output an intermediate stage intermOut :: Options -> Dump -> Doc -> IOE () intermOut opts d doc - | dump opts d = ioeIO (hPutStrLn stderr (encodeUTF8 (render (text "\n\n--#" <+> text (show d) $$ doc)))) + | dump opts d = ioeIO (hPutStrLn stderr (render (text "\n\n--#" <+> text (show d) $$ doc))) | otherwise = return () -- | the environment @@ -162,7 +161,8 @@ compileOne opts env@(_,srcgr,_) file = do sm00 <- putpOpt ("- parsing" +++ file) ("- compiling" +++ file ++ "... ") $ getSourceModule opts file - let sm0 = decodeStringsInModule sm00 + enc <- ioeIO $ mkTextEncoding (renameEncoding (flag optEncoding (flagsModule sm00))) + let sm0 = decodeStringsInModule enc sm00 intermOut opts DumpSource (ppModule Qualified sm0) |
