mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-04-23 19:42:50 -06:00
fixed decodeUTF8 for pgf; removed old resources from darcs
This commit is contained in:
@@ -32,7 +32,7 @@ transliteration s = case s of
|
|||||||
|
|
||||||
characterTable :: Transliteration -> String
|
characterTable :: Transliteration -> String
|
||||||
characterTable = unlines . map prOne . Map.assocs . trans_from_unicode where
|
characterTable = unlines . map prOne . Map.assocs . trans_from_unicode where
|
||||||
prOne (i,s) = unwords ["|", show i, "|", encodeUTF8 [toEnum i], "|", s, "|"]
|
prOne (i,s) = unwords ["|", show i, "|", [toEnum i], "|", s, "|"]
|
||||||
|
|
||||||
data Transliteration = Trans {
|
data Transliteration = Trans {
|
||||||
trans_to_unicode :: Map.Map String Int,
|
trans_to_unicode :: Map.Map String Int,
|
||||||
|
|||||||
@@ -172,7 +172,7 @@ startCat :: PGF -> Category
|
|||||||
---------------------------------------------------
|
---------------------------------------------------
|
||||||
|
|
||||||
readPGF f = do
|
readPGF f = do
|
||||||
s <- readFile f
|
s <- readFile f >>= return . decodeUTF8 -- pgf is in UTF8, internal in unicode
|
||||||
g <- parseGrammar s
|
g <- parseGrammar s
|
||||||
return $! toPGF g
|
return $! toPGF g
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user