summaryrefslogtreecommitdiff
path: root/src/compiler/GF
diff options
context:
space:
mode:
authorkr.angelov <kr.angelov@gmail.com>2012-12-14 15:32:49 +0000
committerkr.angelov <kr.angelov@gmail.com>2012-12-14 15:32:49 +0000
commit20aaa4a9899ce454d3c20594a2b7d2d3d38dbc88 (patch)
tree0f2556c655a29e08cb961b6aa56f0c6d51aa51b6 /src/compiler/GF
parent9ab3a6034d017f87bfc62ac2fc9351e514841a24 (diff)
The first prototype for exhaustive generation in the C runtime. The trees are always listed in decreasing probability order. There is also an API for generation from Python
Diffstat (limited to 'src/compiler/GF')
-rw-r--r--src/compiler/GF/Compile/GrammarToPGF.hs4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/compiler/GF/Compile/GrammarToPGF.hs b/src/compiler/GF/Compile/GrammarToPGF.hs
index f9b008bf8..6fc572fc9 100644
--- a/src/compiler/GF/Compile/GrammarToPGF.hs
+++ b/src/compiler/GF/Compile/GrammarToPGF.hs
@@ -25,7 +25,6 @@ import GF.Infra.Option
import GF.Data.Operations
import Data.List
-import Data.Function
import Data.Char (isDigit,isSpace)
import qualified Data.Set as Set
import qualified Data.Map as Map
@@ -63,8 +62,7 @@ mkCanon2pgf opts gr am = do
((m,c),AbsCat (Just (L _ cont)),addr) <- adefs]
catfuns cat =
- (map (\x -> (0,snd x)) . sortBy (compare `on` fst))
- [(loc,i2i f) | ((m,f),AbsFun (Just (L loc ty)) _ _ (Just True),_) <- adefs, snd (GM.valCat ty) == cat]
+ [(0,i2i f) | ((m,f),AbsFun (Just (L _ ty)) _ _ (Just True),_) <- adefs, snd (GM.valCat ty) == cat]
mkConcr cm = do
let cflags = concatOptions [mflags mo | (i,mo) <- modules gr, isModCnc mo,