From efb806f22608d9e82ad80e733c20449c80f4c0a6 Mon Sep 17 00:00:00 2001 From: bringert Date: Fri, 5 Jan 2007 17:34:44 +0000 Subject: SISR code now type annotates meta variables directly in grammar, to avoid a separate type annotation step. --- src/GF/Canon/GFCC/DataGFCC.hs | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/GF/Canon') diff --git a/src/GF/Canon/GFCC/DataGFCC.hs b/src/GF/Canon/GFCC/DataGFCC.hs index 389afc5a7..43ce04166 100644 --- a/src/GF/Canon/GFCC/DataGFCC.hs +++ b/src/GF/Canon/GFCC/DataGFCC.hs @@ -35,6 +35,10 @@ lookLin :: GFCC -> CId -> CId -> Term lookLin mcfg lang fun = lookMap TM fun $ lookMap undefined lang $ concretes mcfg +-- | Look up the type of a function. +lookType :: GFCC -> CId -> Type +lookType gfcc f = lookMap (error $ "lookType " ++ show f) f (funs (abstract gfcc)) + linearize :: GFCC -> CId -> Exp -> String linearize mcfg lang = realize . linExp mcfg lang -- cgit v1.2.3