change the PGF.Data.Exp type

This commit is contained in:
krasimir
2008-05-30 09:10:28 +00:00
parent 3d2ce9216d
commit 587eed4eaa
11 changed files with 118 additions and 145 deletions

View File

@@ -62,12 +62,9 @@ functionsToCat gfcc cat =
fs = lookMap [] cat $ catfuns $ abstract gfcc
depth :: Exp -> Int
depth tr = case tr of
DTr _ _ [] -> 1
DTr _ _ ts -> maximum (map depth ts) + 1
tree :: Atom -> [Exp] -> Exp
tree = DTr []
depth (EAbs _ t) = depth t
depth (EApp _ ts) = maximum (0:map depth ts) + 1
depth _ = 1
cftype :: [CId] -> CId -> Type
cftype args val = DTyp [Hyp wildCId (cftype [] arg) | arg <- args] val []
@@ -88,9 +85,6 @@ contextLength :: Type -> Int
contextLength ty = case ty of
DTyp hyps _ _ -> length hyps
exp0 :: Exp
exp0 = tree (AM 0) []
primNotion :: Exp
primNotion = EEq []