summaryrefslogtreecommitdiff
path: root/examples/morpho/FreReal.gf
diff options
context:
space:
mode:
authoraarne <aarne@cs.chalmers.se>2008-08-15 12:41:04 +0000
committeraarne <aarne@cs.chalmers.se>2008-08-15 12:41:04 +0000
commitba78322409e2086a83c03b7b32e84940a24030b0 (patch)
tree87b13411a8d6db544461eef201f4e02207ac0ff1 /examples/morpho/FreReal.gf
parent0475ef3414cff410b826c9f06e6c7043625972fa (diff)
examples of morphological synthesis/analysis as top-level grammars
Diffstat (limited to 'examples/morpho/FreReal.gf')
-rw-r--r--examples/morpho/FreReal.gf71
1 files changed, 71 insertions, 0 deletions
diff --git a/examples/morpho/FreReal.gf b/examples/morpho/FreReal.gf
new file mode 100644
index 000000000..c9dfcc84d
--- /dev/null
+++ b/examples/morpho/FreReal.gf
@@ -0,0 +1,71 @@
+--# -path=.:alltenses
+
+concrete FreReal of Fre = IrregFre ** open (R = CommonRomance), Prelude in {
+
+lincat
+ Display = Str ;
+ Word = R.VF => Str ;
+ Form = {s : Str ; v : R.VF} ;
+ TMood = {s : Str ; v : R.TMood} ;
+ Number = {s : Str ; v : R.Number} ;
+ Person = {s : Str ; v : R.Person} ;
+ NumPersI = {s : Str ; v : R.NumPersI} ;
+ Gender = {s : Str ; v : R.Gender} ;
+ Mood = {s : Str ; v : R.Mood} ;
+
+lin
+ -- display the same subset of forms as Petit Robert
+
+ DAll w =
+ w ! R.VInfin True ++
+ w ! R.VFin (R.VPres R.Indic) R.Sg R.P1 ++
+ w ! R.VFin (R.VPres R.Indic) R.Sg R.P3 ++
+ w ! R.VFin (R.VPres R.Indic) R.Pl R.P1 ++
+ w ! R.VFin (R.VPres R.Indic) R.Pl R.P3 ++
+ w ! R.VFin (R.VImperf R.Indic) R.Sg R.P1 ++
+ w ! R.VFin (R.VImperf R.Indic) R.Pl R.P1 ++
+ w ! R.VFin R.VPasse R.Sg R.P1 ++
+ w ! R.VFin R.VPasse R.Pl R.P1 ++
+ w ! R.VFin R.VFut R.Sg R.P1 ++
+ w ! R.VFin R.VCondit R.Sg R.P1 ++
+ w ! R.VFin (R.VPres R.Conjunct) R.Sg R.P1 ++
+ w ! R.VImper R.SgP2 ++
+ w ! R.VImper R.PlP1 ++
+ w ! R.VGer ++
+ w ! R.VPart R.Masc R.Sg ;
+
+ DForm w f = w ! f.v ++ f.s ; ---
+
+ VInfin = {s = [] ; v = R.VInfin True} ;
+ VFin m n p = {s = m.s ++ n.s ++ p.s ; v = R.VFin m.v n.v p.v} ;
+
+ VImper np = {s = np.s ; v = R.VImper np.v} ;
+ VPart g n = {s = g.s ++ n.s ; v = R.VPart g.v n.v} ;
+ VGer = {s = [] ; v = R.VGer} ;
+
+ VPres m = {s = m.s ; v = R.VPres m.v} ;
+ VImperf m = {s = m.s ; v = R.VImperf m.v} ;
+ VPasse = {s = [] ; v = R.VPasse} ;
+ VFut = {s = [] ; v = R.VFut} ;
+ VCondit = {s = [] ; v = R.VCondit} ;
+
+ SgP2 = {s = [] ; v = R.SgP2} ;
+ PlP1 = {s = [] ; v = R.PlP1} ;
+ PlP2 = {s = [] ; v = R.PlP2} ;
+ Sg = {s = [] ; v = R.Sg} ;
+ Pl = {s = [] ; v = R.Pl} ;
+ P1 = {s = [] ; v = R.P1} ;
+ P2 = {s = [] ; v = R.P2} ;
+ P3 = {s = [] ; v = R.P3} ;
+ Masc = {s = [] ; v = R.Masc} ;
+ Fem = {s = [] ; v = R.Fem} ;
+ Indic = {s = [] ; v = R.Indic} ;
+ Conjunct = {s = [] ; v = R.Conjunct} ;
+
+ WVerb v = v.s ;
+ WVerb2 v = v.s ;
+
+oper
+ vf : R.VF -> {s : Str ; v : R.VF} = \f -> {s = [] ; v = f} ; ---
+
+}