From a42a232c5756593e0681598f940c84f555af09d8 Mon Sep 17 00:00:00 2001 From: aarne Date: Tue, 4 Apr 2006 14:44:46 +0000 Subject: inherent features of Int --- src/GF/UseGrammar/Linear.hs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/GF/UseGrammar') diff --git a/src/GF/UseGrammar/Linear.hs b/src/GF/UseGrammar/Linear.hs index d4483bef5..86c5fad3e 100644 --- a/src/GF/UseGrammar/Linear.hs +++ b/src/GF/UseGrammar/Linear.hs @@ -60,8 +60,8 @@ linearizeToRecord gr mk m = lin [] where r <- case at of A.AtC f -> lookf c t f >>= comp xs' + A.AtI i -> return $ recInt i A.AtL s -> return $ recS $ tK $ prt at - A.AtI i -> return $ recS $ tK $ prt at A.AtF i -> return $ recS $ tK $ prt at A.AtV x -> lookCat c >>= comp [tK (prt_ at)] A.AtM m -> lookCat c >>= comp [tK (prt_ at)] @@ -79,6 +79,10 @@ linearizeToRecord gr mk m = lin [] where recS t = R [Ass (L (identC "s")) t] ---- + recInt i = R [Ass (L (identC "s")) (tK $ show i), + Ass (L (identC "last")) (EInt (rem i 10)), + Ass (L (identC "size")) (EInt (if i > 9 then 1 else 0))] + lookCat = return . errVal defLindef . look ---- should always be given in the module -- cgit v1.2.3