Strip down format. More early work on compiler. Add testsuite (doesn't work yet).

This commit is contained in:
John J. Camilleri
2021-01-25 12:10:30 +01:00
parent cd5881d83a
commit f24c50339b
9 changed files with 245 additions and 92 deletions

19
testsuite/lpgf/ZeroEng.gf Normal file
View File

@@ -0,0 +1,19 @@
-- From Angelov, Bringert, Ranta (2009)
concrete ZeroEng of Zero = {
lincat
S = Str ;
NP = {s : Str; n : Number} ;
VP = {s : Number => Str} ;
lin
And s1 s2 = s1 ++ "and" ++ s2 ;
Pred np vp = np.s ++ vp.s ! np.n ;
John = {s = "John"; n = Sg} ;
We = {s = "we"; n = Pl} ;
Walk = {s = table {
Sg => "walks";
Pl => "walk"
}
} ;
param
Number = Sg | Pl ;
}