resource specialized to present tense ; preprocessor flag

This commit is contained in:
aarne
2006-02-25 18:59:32 +00:00
parent af0dfe0921
commit 9b0036457c
57 changed files with 6560 additions and 6493 deletions

View File

@@ -1,4 +1,4 @@
--# -path=.:compiled:prelude:resource-1.0/swadesh --# -path=.:resource-1.0/present:prelude:compiled
concrete BronzeageEng of Bronzeage = CatEng, SwadeshEng ** BronzeageI with concrete BronzeageEng of Bronzeage = CatEng, SwadeshEng ** BronzeageI with
(Lang = LangEng), (Lang = LangEng),

View File

@@ -1,4 +1,4 @@
--# -path=.:compiled:resource-1.0/swadesh --# -path=.:resource-1.0/present:prelude
concrete BronzeageFin of Bronzeage = CatFin, SwadeshFin ** BronzeageI with concrete BronzeageFin of Bronzeage = CatFin, SwadeshFin ** BronzeageI with
(Lang = LangFin), (Lang = LangFin),

View File

@@ -1,4 +1,4 @@
--# -path=.:compiled:prelude:resource-1.0/swadesh --# -path=.:resource-1.0/present:prelude:compiled
concrete BronzeageFre of Bronzeage = CatFre, SwadeshFre ** BronzeageI with concrete BronzeageFre of Bronzeage = CatFre, SwadeshFre ** BronzeageI with
(Lang = LangFre), (Lang = LangFre),

View File

@@ -1,4 +1,4 @@
--# -path=.:compiled:resource-1.0/swadesh --# -path=.:resource-1.0/present:prelude:compiled
concrete BronzeageGer of Bronzeage = CatGer, SwadeshGer ** BronzeageI with concrete BronzeageGer of Bronzeage = CatGer, SwadeshGer ** BronzeageI with
(Lang = LangGer), (Lang = LangGer),

View File

@@ -1,4 +1,4 @@
--# -path=.:compiled:prelude:resource-1.0/swadesh --# -path=.:resource-1.0/present:prelude:compiled
concrete BronzeageIta of Bronzeage = CatIta, SwadeshIta ** BronzeageI with concrete BronzeageIta of Bronzeage = CatIta, SwadeshIta ** BronzeageI with
(Lang = LangIta), (Lang = LangIta),

View File

@@ -1,4 +1,4 @@
--# -path=.:compiled:prelude:resource-1.0/swadesh --# -path=.:resource-1.0/present:prelude:compiled
concrete BronzeageNor of Bronzeage = CatNor, SwadeshNor ** BronzeageI with concrete BronzeageNor of Bronzeage = CatNor, SwadeshNor ** BronzeageI with
(Lang = LangNor), (Lang = LangNor),

View File

@@ -1,4 +1,4 @@
--# -path=.:compiled:prelude:resource-1.0/swadesh --# -path=.:resource-1.0/present:prelude:compiled
concrete BronzeageSpa of Bronzeage = CatSpa, SwadeshSpa ** BronzeageI with concrete BronzeageSpa of Bronzeage = CatSpa, SwadeshSpa ** BronzeageI with
(Lang = LangSpa), (Lang = LangSpa),

View File

@@ -1,4 +1,4 @@
--# -path=.:compiled:prelude:resource-1.0/swadesh --# -path=.:resource-1.0/present:prelude:compiled
concrete BronzeageSwe of Bronzeage = CatSwe, SwadeshSwe ** BronzeageI with concrete BronzeageSwe of Bronzeage = CatSwe, SwadeshSwe ** BronzeageI with
(Lang = LangSwe), (Lang = LangSwe),

View File

@@ -1,4 +1,4 @@
--# -path=.:../finnish:../common:../abstract:../../prelude --# -path=.:../present:../finnish:../common:../abstract:../../prelude
concrete SwadeshFin of Swadesh = CatFin concrete SwadeshFin of Swadesh = CatFin
** open MorphoFin, LangFin, ParadigmsFin, Prelude in { ** open MorphoFin, LangFin, ParadigmsFin, Prelude in {

View File

@@ -1,19 +1,23 @@
all: langs mathematical multimodal all: langs mathematical multimodal
test: test: langs
echo "gr -cat=Text -number=11 -prob | tb" | gf -nocf -probs=lang.gfprob langs.gfcm echo "gr -cat=Text -number=11 -prob | tb" | gf -nocf -probs=lang.gfprob langs.gfcm
langs: langs:
echo "s ;; pm | wf langs.gfcm" | gf -nocf */Lang??*.gf english/LangEng.gf +RTS -M500M -K100M echo "s ;; pm | wf langs.gfcm" | gf -nocf */Lang??*.gf english/LangEng.gf +RTS -M500M -K100M
mathematical: present:
gf -nocf -gfc mathematical/Mathematical???.gf +RTS -M800M -K100M gf -batch -nocf -preproc=./mkPresent */Lang??*.gf
cp -p */*.gfc */*.gfr present
multimodal: mathematical: present
gf -nocf -gfc multimodal/Multimodal???.gf +RTS -M500M -K100M gf -batch -nocf -preproc=./mkPresent mathematical/Mathematical???.gf
multimodal: present
gf -batch -nocf -preproc=./mkPresent multimodal/Multimodal???.gf
install: install:
cp -p */*.gfc */*.gfr ../compiled cp -p */*.gfc */*.gfr langs
stat: stat:
wc */*.gfc wc */*.gfc

View File

@@ -5,14 +5,14 @@
-- forms of sentences. Together they give 2 x 4 x 4 = 16 sentence forms. -- forms of sentences. Together they give 2 x 4 x 4 = 16 sentence forms.
-- These tenses are defined for all languages in the library. More tenses -- These tenses are defined for all languages in the library. More tenses
-- can be defined in the language extensions, e.g. the "passé simple" of -- can be defined in the language extensions, e.g. the "passé simple" of
-- Romance languages. -- Romance languages.
abstract Common = { abstract Common = {
cat cat
Text ; -- text consisting of several phrases Text ; -- text consisting of several phrases
Phr ; -- phrase in a text e.g. "But be quiet my darling." Phr ; -- phrase in a text e.g. "But come here my darling."
Pol ; Pol ;
Tense ; Tense ;
@@ -20,7 +20,10 @@ abstract Common = {
fun fun
PPos, PNeg : Pol ; -- I sleep/don't sleep PPos, PNeg : Pol ; -- I sleep/don't sleep
TPres, TPast, TFut, TCond : Tense ; -- I sleep/slept/will sleep/would sleep
ASimul, AAnter : Ant ; -- I sleep/have slept TPres : Tense ;
ASimul : Ant ;
TPast, TFut, TCond : Tense ; -- I slept/will sleep/would sleep --# notpresent
AAnter : Ant ; -- I have slept --# notpresent
} }

View File

@@ -11,10 +11,10 @@ concrete CommonX of Common = open (R = ParamX) in {
PPos = {s = []} ** {p = R.Pos} ; PPos = {s = []} ** {p = R.Pos} ;
PNeg = {s = []} ** {p = R.Neg} ; PNeg = {s = []} ** {p = R.Neg} ;
TPres = {s = []} ** {t = R.Pres} ; TPres = {s = []} ** {t = R.Pres} ;
TPast = {s = []} ** {t = R.Past} ; TPast = {s = []} ** {t = R.Past} ; --# notpresent
TFut = {s = []} ** {t = R.Fut} ; TFut = {s = []} ** {t = R.Fut} ; --# notpresent
TCond = {s = []} ** {t = R.Cond} ; TCond = {s = []} ** {t = R.Cond} ; --# notpresent
ASimul = {s = []} ** {a = R.Simul} ; ASimul = {s = []} ** {a = R.Simul} ;
AAnter = {s = []} ** {a = R.Anter} ; AAnter = {s = []} ** {a = R.Anter} ; --# notpresent
} }

View File

@@ -5,8 +5,19 @@ resource ParamX = open Prelude in {
Person = P1 | P2 | P3 ; Person = P1 | P2 | P3 ;
Degree = Posit | Compar | Superl ; Degree = Posit | Compar | Superl ;
Anteriority = Simul | Anter ; Anteriority =
Tense = Pres | Past | Fut | Cond ; Simul
| Anter --# notpresent
;
Tense =
Pres
| Past --# notpresent
| Fut --# notpresent
| Cond --# notpresent
;
param
Polarity = Pos | Neg ; Polarity = Pos | Neg ;
QForm = QDir | QIndir ; QForm = QDir | QIndir ;

View File

@@ -37,6 +37,7 @@ concrete CatEng of Cat = CommonX ** open ResEng, Prelude in {
VP = { VP = {
s : Tense => Anteriority => Polarity => Order => Agr => {fin, inf : Str} ; s : Tense => Anteriority => Polarity => Order => Agr => {fin, inf : Str} ;
prp : Str ; -- present participle prp : Str ; -- present participle
inf : Str ; -- infinitive
ad : Str ; ad : Str ;
s2 : Agr => Str s2 : Agr => Str
} ; } ;

View File

@@ -34,11 +34,21 @@ resource ResEng = ParamX ** open Prelude in {
-- Only these five forms are needed for open-lexicon verbs. -- Only these five forms are needed for open-lexicon verbs.
param param
VForm = VInf | VPres | VPast | VPPart | VPresPart ; VForm =
VInf
| VPres
| VPPart
| VPresPart
| VPast --# notpresent
;
-- Auxiliary verbs have special negative forms. -- Auxiliary verbs have special negative forms.
VVForm = VVF VForm | VVPresNeg | VVPastNeg ; VVForm =
VVF VForm
| VVPresNeg
| VVPastNeg --# notpresent
;
-- The order of sentence is needed already in $VP$. -- The order of sentence is needed already in $VP$.
@@ -102,7 +112,7 @@ resource ResEng = ParamX ** open Prelude in {
s = table { s = table {
VInf => go ; VInf => go ;
VPres => goes ; VPres => goes ;
VPast => went ; VPast => went ; --# notpresent
VPPart => gone ; VPPart => gone ;
VPresPart => going VPresPart => going
} ; } ;
@@ -164,6 +174,7 @@ resource ResEng = ParamX ** open Prelude in {
VP : Type = { VP : Type = {
s : VerbForms ; s : VerbForms ;
prp : Str ; -- present participle prp : Str ; -- present participle
inf : Str ; -- infinitive
ad : Str ; ad : Str ;
s2 : Agr => Str s2 : Agr => Str
} ; } ;
@@ -176,7 +187,6 @@ resource ResEng = ParamX ** open Prelude in {
let let
inf = verb.s ! VInf ; inf = verb.s ! VInf ;
fin = presVerb verb agr ; fin = presVerb verb agr ;
past = verb.s ! VPast ;
part = verb.s ! VPPart ; part = verb.s ! VPPart ;
vf : Str -> Str -> {fin, inf : Str} = \x,y -> vf : Str -> Str -> {fin, inf : Str} = \x,y ->
{fin = x ; inf = y} ; {fin = x ; inf = y} ;
@@ -184,24 +194,25 @@ resource ResEng = ParamX ** open Prelude in {
case <t,ant,b,ord> of { case <t,ant,b,ord> of {
<Pres,Simul,Pos,ODir> => vf fin [] ; --- should be opp <Pres,Simul,Pos,ODir> => vf fin [] ; --- should be opp
<Pres,Simul,Pos,OQuest> => vf (does agr) inf ; <Pres,Simul,Pos,OQuest> => vf (does agr) inf ;
<Pres,Simul,Neg,_> => vf (doesnt agr) inf ; <Pres,Anter,Pos,_> => vf (have agr) part ; --# notpresent
<Pres,Anter,Pos,_> => vf (have agr) part ; <Pres,Anter,Neg,_> => vf (havent agr) part ; --# notpresent
<Pres,Anter,Neg,_> => vf (havent agr) part ; <Past,Simul,Pos,ODir> => vf (verb.s ! VPast) [] ; --# notpresent --- should be opp
<Past,Simul,Pos,ODir> => vf past [] ; --- should be opp <Past,Simul,Pos,OQuest> => vf "did" inf ; --# notpresent
<Past,Simul,Pos,OQuest> => vf "did" inf ; <Past,Simul,Neg,_> => vf "didn't" inf ; --# notpresent
<Past,Simul,Neg,_> => vf "didn't" inf ; <Past,Anter,Pos,_> => vf "had" part ; --# notpresent
<Past,Anter,Pos,_> => vf "had" part ; <Past,Anter,Neg,_> => vf "hadn't" part ; --# notpresent
<Past,Anter,Neg,_> => vf "hadn't" part ; <Fut, Simul,Pos,_> => vf "will" inf ; --# notpresent
<Fut, Simul,Pos,_> => vf "will" inf ; <Fut, Simul,Neg,_> => vf "won't" inf ; --# notpresent
<Fut, Simul,Neg,_> => vf "won't" inf ; <Fut, Anter,Pos,_> => vf "will" ("have" ++ part) ; --# notpresent
<Fut, Anter,Pos,_> => vf "will" ("have" ++ part) ; <Fut, Anter,Neg,_> => vf "won't" ("have" ++ part) ; --# notpresent
<Fut, Anter,Neg,_> => vf "won't" ("have" ++ part) ; <Cond,Simul,Pos,_> => vf "would" inf ; --# notpresent
<Cond,Simul,Pos,_> => vf "would" inf ; <Cond,Simul,Neg,_> => vf "wouldn't" inf ; --# notpresent
<Cond,Simul,Neg,_> => vf "wouldn't" inf ; <Cond,Anter,Pos,_> => vf "would" ("have" ++ part) ; --# notpresent
<Cond,Anter,Pos,_> => vf "would" ("have" ++ part) ; <Cond,Anter,Neg,_> => vf "wouldn't" ("have" ++ part) ; --# notpresent
<Cond,Anter,Neg,_> => vf "wouldn't" ("have" ++ part) <Pres,Simul,Neg,_> => vf (doesnt agr) inf
} ; } ;
prp = verb.s ! VPresPart ; prp = verb.s ! VPresPart ;
inf = verb.s ! VInf ;
ad = [] ; ad = [] ;
s2 = \\a => if_then_Str verb.isRefl (reflPron ! a) [] s2 = \\a => if_then_Str verb.isRefl (reflPron ! a) []
} ; } ;
@@ -211,28 +222,28 @@ resource ResEng = ParamX ** open Prelude in {
let let
inf = verb.inf ; inf = verb.inf ;
fin = verb.pres ! b ! agr ; fin = verb.pres ! b ! agr ;
past = verb.past ! b ! agr ;
part = verb.ppart ; part = verb.ppart ;
vf : Str -> Str -> {fin, inf : Str} = \x,y -> vf : Str -> Str -> {fin, inf : Str} = \x,y ->
{fin = x ; inf = y} ; {fin = x ; inf = y} ;
in in
case <t,ant,b,ord> of { case <t,ant,b,ord> of {
<Pres,Simul,_, _> => vf fin [] ; <Pres,Anter,Pos,_> => vf (have agr) part ; --# notpresent
<Pres,Anter,Pos,_> => vf (have agr) part ; <Pres,Anter,Neg,_> => vf (havent agr) part ; --# notpresent
<Pres,Anter,Neg,_> => vf (havent agr) part ; <Past,Simul,_, _> => vf (verb.past ! b ! agr) [] ; --# notpresent
<Past,Simul,_, _> => vf past [] ; <Past,Anter,Pos,_> => vf "had" part ; --# notpresent
<Past,Anter,Pos,_> => vf "had" part ; <Past,Anter,Neg,_> => vf "hadn't" part ; --# notpresent
<Past,Anter,Neg,_> => vf "hadn't" part ; <Fut, Simul,Pos,_> => vf "will" inf ; --# notpresent
<Fut, Simul,Pos,_> => vf "will" inf ; <Fut, Simul,Neg,_> => vf "won't" inf ; --# notpresent
<Fut, Simul,Neg,_> => vf "won't" inf ; <Fut, Anter,Pos,_> => vf "will" ("have" ++ part) ; --# notpresent
<Fut, Anter,Pos,_> => vf "will" ("have" ++ part) ; <Fut, Anter,Neg,_> => vf "won't" ("have" ++ part) ; --# notpresent
<Fut, Anter,Neg,_> => vf "won't" ("have" ++ part) ; <Cond,Simul,Pos,_> => vf "would" inf ; --# notpresent
<Cond,Simul,Pos,_> => vf "would" inf ; <Cond,Simul,Neg,_> => vf "wouldn't" inf ; --# notpresent
<Cond,Simul,Neg,_> => vf "wouldn't" inf ; <Cond,Anter,Pos,_> => vf "would" ("have" ++ part) ; --# notpresent
<Cond,Anter,Pos,_> => vf "would" ("have" ++ part) ; <Cond,Anter,Neg,_> => vf "wouldn't" ("have" ++ part) ; --# notpresent
<Cond,Anter,Neg,_> => vf "wouldn't" ("have" ++ part) <Pres,Simul,_, _> => vf fin []
} ; } ;
prp = verb.prpart ; prp = verb.prpart ;
inf = verb.inf ;
ad = [] ; ad = [] ;
s2 = \\_ => [] s2 = \\_ => []
} ; } ;
@@ -240,6 +251,7 @@ resource ResEng = ParamX ** open Prelude in {
insertObj : (Agr => Str) -> VP -> VP = \obj,vp -> { insertObj : (Agr => Str) -> VP -> VP = \obj,vp -> {
s = vp.s ; s = vp.s ;
prp = vp.prp ; prp = vp.prp ;
inf = vp.inf ;
ad = vp.ad ; ad = vp.ad ;
s2 = \\a => vp.s2 ! a ++ obj ! a s2 = \\a => vp.s2 ! a ++ obj ! a
} ; } ;
@@ -249,6 +261,7 @@ resource ResEng = ParamX ** open Prelude in {
insertAdV : Str -> VP -> VP = \adv,vp -> { insertAdV : Str -> VP -> VP = \adv,vp -> {
s = vp.s ; s = vp.s ;
prp = vp.prp ; prp = vp.prp ;
inf = vp.inf ;
ad = vp.ad ++ adv ; ad = vp.ad ++ adv ;
s2 = \\a => vp.s2 ! a s2 = \\a => vp.s2 ! a
} ; } ;
@@ -264,10 +277,10 @@ resource ResEng = ParamX ** open Prelude in {
Pos => \\_ => verbs ! VVF VPres ; Pos => \\_ => verbs ! VVF VPres ;
Neg => \\_ => verbs ! VVPresNeg Neg => \\_ => verbs ! VVPresNeg
} ; } ;
past = table { past = table { --# notpresent
Pos => \\_ => verbs ! VVF VPast ; Pos => \\_ => verbs ! VVF VPast ; --# notpresent
Neg => \\_ => verbs ! VVPastNeg Neg => \\_ => verbs ! VVPastNeg --# notpresent
} ; } ; --# notpresent
inf = verbs ! VVF VInf ; inf = verbs ! VVF VInf ;
ppart = verbs ! VVF VPPart ; ppart = verbs ! VVF VPPart ;
prpart = verbs ! VVF VPresPart ; prpart = verbs ! VVF VPresPart ;
@@ -280,7 +293,7 @@ resource ResEng = ParamX ** open Prelude in {
infVP : Bool -> VP -> Agr -> Str = \isAux,vp,a -> infVP : Bool -> VP -> Agr -> Str = \isAux,vp,a ->
if_then_Str isAux [] "to" ++ if_then_Str isAux [] "to" ++
(vp.s ! Fut ! Simul ! Neg ! ODir ! a).inf ++ vp.s2 ! a ; vp.inf ++ vp.s2 ! a ;
agrVerb : Str -> Str -> Agr -> Str = \has,have,agr -> agrVerb : Str -> Str -> Agr -> Str = \has,have,agr ->
case agr of { case agr of {
@@ -293,7 +306,11 @@ resource ResEng = ParamX ** open Prelude in {
does = agrVerb "does" "do" ; does = agrVerb "does" "do" ;
doesnt = agrVerb "doesn't" "don't" ; doesnt = agrVerb "doesn't" "don't" ;
Aux = {pres,past : Polarity => Agr => Str ; inf,ppart,prpart : Str} ; Aux = {
pres : Polarity => Agr => Str ;
past : Polarity => Agr => Str ; --# notpresent
inf,ppart,prpart : Str
} ;
auxBe : Aux = { auxBe : Aux = {
pres = \\b,a => case <b,a> of { pres = \\b,a => case <b,a> of {
@@ -301,10 +318,10 @@ resource ResEng = ParamX ** open Prelude in {
<Neg,{n = Sg ; p = P1}> => ["am not"] ; --- am not I <Neg,{n = Sg ; p = P1}> => ["am not"] ; --- am not I
_ => agrVerb (posneg b "is") (posneg b "are") a _ => agrVerb (posneg b "is") (posneg b "are") a
} ; } ;
past = \\b,a => case a of { past = \\b,a => case a of { --# notpresent
{n = Sg ; p = P1|P3} => (posneg b "was") ; {n = Sg ; p = P1|P3} => (posneg b "was") ; --# notpresent
_ => (posneg b "were") _ => (posneg b "were") --# notpresent
} ; } ; --# notpresent
inf = "be" ; inf = "be" ;
ppart = "been" ; ppart = "been" ;
prpart = "being" prpart = "being"

View File

@@ -69,8 +69,8 @@ param
VForm = VForm =
Inf InfForm Inf InfForm
| Presn Number Person | Presn Number Person
| Impf Number Person | Impf Number Person --# notpresent
| Condit Number Person | Condit Number Person --# notpresent
| Imper Number | Imper Number
| ImperP3 Number | ImperP3 Number
| ImperP1Pl | ImperP1Pl
@@ -169,10 +169,11 @@ oper
} ; } ;
einegole : Str * Str * Str = case <vi,agr.n> of { einegole : Str * Str * Str = case <vi,agr.n> of {
<VIFin (Pres | Fut),_> => <eiv, verbs ! Imper Sg, "ole"> ; <VIFin Pres,_> => <eiv, verbs ! Imper Sg, "ole"> ;
<VIFin Cond, _> => <eiv, verbs ! Condit Sg P3, "olisi"> ; <VIFin Fut,_> => <eiv, verbs ! Imper Sg, "ole"> ; --# notpresent
<VIFin Past, Sg> => <eiv, part, "ollut"> ; <VIFin Cond, _> => <eiv, verbs ! Condit Sg P3, "olisi"> ; --# notpresent
<VIFin Past, Pl> => <eiv, part, "olleet"> ; <VIFin Past, Sg> => <eiv, part, "ollut"> ; --# notpresent
<VIFin Past, Pl> => <eiv, part, "olleet"> ; --# notpresent
<VIImper, Sg> => <"älä", verbs ! Imper Sg, "ole"> ; <VIImper, Sg> => <"älä", verbs ! Imper Sg, "ole"> ;
<VIImper, Pl> => <"älkää", verbs ! ImpNegPl, "olko"> ; <VIImper, Pl> => <"älkää", verbs ! ImpNegPl, "olko"> ;
<VIPass, _> => <"ei", verbs ! Pass False, "ole"> ; <VIPass, _> => <"ei", verbs ! Pass False, "ole"> ;
@@ -189,15 +190,16 @@ oper
{fin = x ; inf = y} ; {fin = x ; inf = y} ;
mkvf : VForm -> {fin, inf : Str} = \p -> case <ant,b> of { mkvf : VForm -> {fin, inf : Str} = \p -> case <ant,b> of {
<Simul,Pos> => vf (verbs ! p) [] ; <Simul,Pos> => vf (verbs ! p) [] ;
<Simul,Neg> => vf ei neg ; <Anter,Pos> => vf (olla ! p) part ; --# notpresent
<Anter,Pos> => vf (olla ! p) part ; <Anter,Neg> => vf ei (ole ++ part) ; --# notpresent
<Anter,Neg> => vf ei (ole ++ part) <Simul,Neg> => vf ei neg
} }
in in
case vi of { case vi of {
VIFin Past => mkvf (Impf agr.n agr.p) ; VIFin Past => mkvf (Impf agr.n agr.p) ; --# notpresent
VIFin Cond => mkvf (Condit agr.n agr.p) ; VIFin Cond => mkvf (Condit agr.n agr.p) ; --# notpresent
VIFin (Pres | Fut) => mkvf (Presn agr.n agr.p) ; VIFin Fut => mkvf (Presn agr.n agr.p) ; --# notpresent
VIFin Pres => mkvf (Presn agr.n agr.p) ;
VIImper => mkvf (Imper agr.n) ; VIImper => mkvf (Imper agr.n) ;
VIPass => mkvf (Pass True) ; VIPass => mkvf (Pass True) ;
VIInf i => mkvf (Inf i) VIInf i => mkvf (Inf i)
@@ -318,18 +320,18 @@ oper
Presn Pl P1 => tuje + "mme" ; Presn Pl P1 => tuje + "mme" ;
Presn Pl P2 => tuje + "tte" ; Presn Pl P2 => tuje + "tte" ;
Presn Pl P3 => tulevat ; Presn Pl P3 => tulevat ;
Impf Sg P1 => tuji + "n" ; Impf Sg P1 => tuji + "n" ; --# notpresent
Impf Sg P2 => tuji + "t" ; Impf Sg P2 => tuji + "t" ; --# notpresent
Impf Sg P3 => tuli ; Impf Sg P3 => tuli ; --# notpresent
Impf Pl P1 => tuji + "mme" ; Impf Pl P1 => tuji + "mme" ; --# notpresent
Impf Pl P2 => tuji + "tte" ; Impf Pl P2 => tuji + "tte" ; --# notpresent
Impf Pl P3 => tuli + vat ; Impf Pl P3 => tuli + vat ; --# notpresent
Condit Sg P1 => tulisi + "n" ; Condit Sg P1 => tulisi + "n" ; --# notpresent
Condit Sg P2 => tulisi + "t" ; Condit Sg P2 => tulisi + "t" ; --# notpresent
Condit Sg P3 => tulisi ; Condit Sg P3 => tulisi ; --# notpresent
Condit Pl P1 => tulisi + "mme" ; Condit Pl P1 => tulisi + "mme" ; --# notpresent
Condit Pl P2 => tulisi + "tte" ; Condit Pl P2 => tulisi + "tte" ; --# notpresent
Condit Pl P3 => tulisi + vat ; Condit Pl P3 => tulisi + vat ; --# notpresent
Imper Sg => tuje ; Imper Sg => tuje ;
Imper Pl => tulkaa ; Imper Pl => tulkaa ;
ImperP3 Sg => tulko + o + "n" ; ImperP3 Sg => tulko + o + "n" ;

View File

@@ -227,11 +227,11 @@ oper
VInfin => aller ! Inf ; VInfin => aller ! Inf ;
VFin (VPres Indic) n p => aller ! Indi Presn n p ; VFin (VPres Indic) n p => aller ! Indi Presn n p ;
VFin (VPres Subjunct) n p => aller ! Subjo SPres n p ; VFin (VPres Subjunct) n p => aller ! Subjo SPres n p ;
VFin (VImperf Indic) n p => aller ! Indi Imparf n p ; VFin (VImperf Indic) n p => aller ! Indi Imparf n p ; --# notpresent
VFin (VImperf Subjunct) n p => aller ! Subjo SImparf n p ; VFin (VImperf Subjunct) n p => aller ! Subjo SImparf n p ; --# notpresent
VFin VPasse n p => aller ! Indi Passe n p ; VFin VPasse n p => aller ! Indi Passe n p ; --# notpresent
VFin VFut n p => aller ! Indi Futur n p ; VFin VFut n p => aller ! Indi Futur n p ; --# notpresent
VFin VCondit n p => aller ! Condi n p ; VFin VCondit n p => aller ! Condi n p ; --# notpresent
VImper np => aller ! Imper np ; VImper np => aller ! Imper np ;
VPart g n => aller ! Part (PPasse g n) ; VPart g n => aller ! Part (PPasse g n) ;
VGer => aller ! Part PPres -- *en* allant VGer => aller ! Part PPres -- *en* allant

View File

@@ -52,8 +52,8 @@ resource ResGer = ParamX ** open Prelude in {
| VPresInd Number Person | VPresInd Number Person
| VPresSubj Number Person | VPresSubj Number Person
| VImper Number | VImper Number
| VImpfInd Number Person | VImpfInd Number Person --# notpresent
| VImpfSubj Number Person | VImpfSubj Number Person --# notpresent
| VPresPart AForm | VPresPart AForm
| VPastPart AForm ; | VPastPart AForm ;
@@ -130,7 +130,7 @@ resource ResGer = ParamX ** open Prelude in {
vFin : Tense -> Agr -> VForm = \t,a -> vFin : Tense -> Agr -> VForm = \t,a ->
case t of { case t of {
Pres => VPresInd a.n a.p ; Pres => VPresInd a.n a.p ;
Past => VImpfInd a.n a.p ; Past => VImpfInd a.n a.p ; --# notpresent
_ => VInf --- never used _ => VInf --- never used
} ; } ;
@@ -211,14 +211,14 @@ resource ResGer = ParamX ** open Prelude in {
VPresSubj Pl P2 => init geben + "t" ; VPresSubj Pl P2 => init geben + "t" ;
VPresSubj Pl _ => geben ; VPresSubj Pl _ => geben ;
VPresPart a => (regA (geben + "d")).s ! Posit ! a ; VPresPart a => (regA (geben + "d")).s ! Posit ! a ;
VImpfInd Sg P2 => gabst ; VImpfInd Sg P2 => gabst ; --# notpresent
VImpfInd Sg _ => gab ; VImpfInd Sg _ => gab ; --# notpresent
VImpfInd Pl P2 => gabt ; VImpfInd Pl P2 => gabt ; --# notpresent
VImpfInd Pl _ => gaben ; VImpfInd Pl _ => gaben ; --# notpresent
VImpfSubj Sg P2 => gaebe + "st" ; VImpfSubj Sg P2 => gaebe + "st" ; --# notpresent
VImpfSubj Sg _ => gaebe ; VImpfSubj Sg _ => gaebe ; --# notpresent
VImpfSubj Pl P2 => gaebe + "t" ; VImpfSubj Pl P2 => gaebe + "t" ; --# notpresent
VImpfSubj Pl _ => gaebe + "n" ; VImpfSubj Pl _ => gaebe + "n" ; --# notpresent
VPastPart a => (regA gegeben).s ! Posit ! a VPastPart a => (regA gegeben).s ! Posit ! a
} ; } ;
prefix = ein ; prefix = ein ;
@@ -346,7 +346,7 @@ resource ResGer = ParamX ** open Prelude in {
haben : Str = vHaben ! VInf ; haben : Str = vHaben ! VInf ;
wird : Agr -> Str = \a -> werden_V.s ! VPresInd a.n a.p ; wird : Agr -> Str = \a -> werden_V.s ! VPresInd a.n a.p ;
wuerde : Agr -> Str = \a -> werden_V.s ! VImpfSubj a.n a.p ; wuerde : Agr -> Str = \a -> werden_V.s ! VImpfSubj a.n a.p ; --# notpresent
auf = verb.prefix ; auf = verb.prefix ;
@@ -357,18 +357,20 @@ resource ResGer = ParamX ** open Prelude in {
in { in {
s = \\a => table { s = \\a => table {
VPFinite t Simul => case t of { VPFinite t Simul => case t of {
Pres | Past => vf (vfin t a) [] ; -- Pres | Past => vf (vfin t a) [] ; -- the general rule
Fut => vf (wird a) vinf ; Past => vf (vfin t a) [] ; --# notpresent
Cond => vf (wuerde a) vinf Fut => vf (wird a) vinf ; --# notpresent
} ; Cond => vf (wuerde a) vinf ; --# notpresent
VPFinite t Anter => case t of { Pres => vf (vfin t a) []
Pres | Past => vf (hat t a) vpart ;
Fut => vf (wird a) (vpart ++ haben) ;
Cond => vf (wuerde a) (vpart ++ haben)
} ; } ;
VPFinite t Anter => case t of { --# notpresent
Pres | Past => vf (hat t a) vpart ; --# notpresent
Fut => vf (wird a) (vpart ++ haben) ; --# notpresent
Cond => vf (wuerde a) (vpart ++ haben) --# notpresent
} ; --# notpresent
VPImperat => vf (verb.s ! VImper a.n) [] ; VPImperat => vf (verb.s ! VImper a.n) [] ;
VPInfinit Simul => vf [] vinf ; VPInfinit Anter => vf [] (vpart ++ haben) ; --# notpresent
VPInfinit Anter => vf [] (vpart ++ haben) VPInfinit Simul => vf [] vinf
} ; } ;
a1 : Polarity => Str = negation ; a1 : Polarity => Str = negation ;
n2 : Agr => Str = case verb.vtype of { n2 : Agr => Str = case verb.vtype of {
@@ -503,10 +505,12 @@ resource ResGer = ParamX ** open Prelude in {
compl = obj ++ neg ++ vp.a2 ; compl = obj ++ neg ++ vp.a2 ;
inf = vp.inf ++ verb.inf ; inf = vp.inf ++ verb.inf ;
extra = vp.ext ; extra = vp.ext ;
inffin = case <a,vp.isAux> of { inffin =
<Anter,True> => verb.fin ++ inf ; -- double infinitive case <a,vp.isAux> of { --# notpresent
_ => inf ++ verb.fin --- or just auxiliary vp <Anter,True> => verb.fin ++ inf ; -- double infinitive --# notpresent
} _ => --# notpresent
inf ++ verb.fin --- or just auxiliary vp
} --# notpresent
in in
case o of { case o of {
Main => subj ++ verb.fin ++ compl ++ inf ++ extra ; Main => subj ++ verb.fin ++ compl ++ inf ++ extra ;

File diff suppressed because it is too large Load Diff

View File

@@ -1,4 +1,4 @@
--# -path=.:../english:../abstract:../common:prelude --# -path=.:../present:prelude
concrete MathematicalEng of Mathematical = concrete MathematicalEng of Mathematical =
NounEng - [ComplN2], --- to avoid ambiguity NounEng - [ComplN2], --- to avoid ambiguity

View File

@@ -1,4 +1,4 @@
--# -path=.:../finnish:../abstract:../common:prelude --# -path=.:../present:prelude
concrete MathematicalFin of Mathematical = concrete MathematicalFin of Mathematical =
NounFin - [ComplN2], --- to avoid ambiguity NounFin - [ComplN2], --- to avoid ambiguity

View File

@@ -1,4 +1,4 @@
--# -path=.:../french:../romance:../abstract:../common:prelude --# -path=.:../present:prelude
concrete MathematicalFre of Mathematical = concrete MathematicalFre of Mathematical =
NounFre - [ComplN2], --- to avoid ambiguity NounFre - [ComplN2], --- to avoid ambiguity

View File

@@ -1,4 +1,4 @@
--# -path=.:../german:../abstract:../common:prelude --# -path=.:../present:prelude
concrete MathematicalGer of Mathematical = concrete MathematicalGer of Mathematical =
NounGer - [ComplN2], --- to avoid ambiguity NounGer - [ComplN2], --- to avoid ambiguity

View File

@@ -1,4 +1,4 @@
--# -path=.:../italian:../romance:../abstract:../common:prelude --# -path=.:../present:prelude
concrete MathematicalIta of Mathematical = concrete MathematicalIta of Mathematical =
NounIta - [ComplN2], --- to avoid ambiguity NounIta - [ComplN2], --- to avoid ambiguity

View File

@@ -1,4 +1,4 @@
--# -path=.:../norwegian:../scandinavian:../abstract:../common:prelude --# -path=.:../present:prelude
concrete MathematicalNor of Mathematical = concrete MathematicalNor of Mathematical =
NounNor - [ComplN2], --- to avoid ambiguity NounNor - [ComplN2], --- to avoid ambiguity

View File

@@ -1,4 +1,4 @@
--# -path=.:../spanish:../romance:../abstract:../common:prelude --# -path=.:../present:prelude
concrete MathematicalSpa of Mathematical = concrete MathematicalSpa of Mathematical =
NounSpa - [ComplN2], --- to avoid ambiguity NounSpa - [ComplN2], --- to avoid ambiguity

View File

@@ -1,4 +1,4 @@
--# -path=.:../swedish:../scandinavian:../abstract:../common:prelude --# -path=.:../present:prelude
concrete MathematicalSwe of Mathematical = concrete MathematicalSwe of Mathematical =
NounSwe - [ComplN2], --- to avoid ambiguity NounSwe - [ComplN2], --- to avoid ambiguity

View File

@@ -0,0 +1 @@
grep -v "\-\-\# notpresent" $1

View File

@@ -1,4 +1,4 @@
--# -path=.:../english/:../abstract:../common:prelude --# -path=.:../present:prelude
concrete MultimodalEng of Multimodal = concrete MultimodalEng of Multimodal =
NounEng, NounEng,

View File

@@ -1,4 +1,4 @@
--# -path=.:../finnish/:../abstract:../common:prelude --# -path=.:../present:prelude
concrete MultimodalFin of Multimodal = concrete MultimodalFin of Multimodal =
NounFin, NounFin,

View File

@@ -1,4 +1,4 @@
--# -path=.:../french/:../romance:../abstract:../common:prelude --# -path=.:../present:prelude
concrete MultimodalFre of Multimodal = concrete MultimodalFre of Multimodal =
NounFre, NounFre,

View File

@@ -1,4 +1,4 @@
--# -path=.:../german/:../abstract:../common:prelude --# -path=.:../present:prelude
concrete MultimodalGer of Multimodal = concrete MultimodalGer of Multimodal =
NounGer, NounGer,

View File

@@ -1,4 +1,4 @@
--# -path=.:../italian/:../romance:../abstract:../common:prelude --# -path=.:../present:prelude
concrete MultimodalIta of Multimodal = concrete MultimodalIta of Multimodal =
NounIta, NounIta,

View File

@@ -1,4 +1,4 @@
--# -path=.:../norwegian/:../scandinavian:../abstract:../common:prelude --# -path=.:../present:prelude
concrete MultimodalNor of Multimodal = concrete MultimodalNor of Multimodal =
NounNor, NounNor,

View File

@@ -1,4 +1,4 @@
--# -path=.:../spanish/:../romance:../abstract:../common:prelude --# -path=.:../present:prelude
concrete MultimodalSpa of Multimodal = concrete MultimodalSpa of Multimodal =
NounSpa, NounSpa,

View File

@@ -1,4 +1,4 @@
--# -path=.:../swedish/:../scandinavian:../abstract:../common:prelude --# -path=.:../present:prelude
concrete MultimodalSwe of Multimodal = concrete MultimodalSwe of Multimodal =
NounSwe, NounSwe,

View File

@@ -87,8 +87,8 @@ oper
VI (VInfin v) => mkVoice v spise ; VI (VInfin v) => mkVoice v spise ;
VF (VPres Act) => spiser ; VF (VPres Act) => spiser ;
VF (VPres Pass) => spises ; VF (VPres Pass) => spises ;
VF (VPret v) => mkVoice v spiste ; VF (VPret v) => mkVoice v spiste ; --# notpresent
VI (VSupin v) => mkVoice v spist ; VI (VSupin v) => mkVoice v spist ; --# notpresent
VI (VPtPret (Strong (SgUtr | SgNeutr)) c) => mkCase c spist ; VI (VPtPret (Strong (SgUtr | SgNeutr)) c) => mkCase c spist ;
VI (VPtPret _ c) => case last spist of { VI (VPtPret _ c) => case last spist of {
"a" => mkCase c spist ; "a" => mkCase c spist ;

View File

@@ -91,10 +91,10 @@ param
TMood = TMood =
VPres Mood VPres Mood
| VImperf Mood | VImperf Mood --# notpresent
| VPasse | VPasse --# notpresent
| VFut | VFut --# notpresent
| VCondit | VCondit --# notpresent
; ;
NumPersI = SgP2 | PlP1 | PlP2 ; NumPersI = SgP2 | PlP1 | PlP2 ;

View File

@@ -79,11 +79,11 @@ oper
in { in {
s = table { s = table {
VPFinite t Simul => vf (vfin t) (\_ -> []) ; VPFinite t Simul => vf (vfin t) (\_ -> []) ;
VPFinite t Anter => vf (habet t) vpart ; VPFinite t Anter => vf (habet t) vpart ; --# notpresent
VPInfinit Anter => vf (\_ -> []) (\a -> habere ++ vpart a) ; --# notpresent
VPImperat => vf vimp (\_ -> []) ; VPImperat => vf vimp (\_ -> []) ;
VPGerund => vf (\_ -> []) (\_ -> vger) ; VPGerund => vf (\_ -> []) (\_ -> vger) ;
VPInfinit Simul => vf (\_ -> []) (\_ -> vinf) ; VPInfinit Simul => vf (\_ -> []) (\_ -> vinf)
VPInfinit Anter => vf (\_ -> []) (\a -> habere ++ vpart a)
} ; } ;
agr = partAgr typ ; agr = partAgr typ ;
neg = negation ; neg = negation ;
@@ -174,10 +174,10 @@ oper
s = \\t,a,b,m => s = \\t,a,b,m =>
let let
tm = case t of { tm = case t of {
Pres => VPres m ; Past => VImperf m ; --# notpresent
Past => VImperf m ; Fut => VFut ; --# notpresent
Fut => VFut ; Cond => VCondit ; --# notpresent
Cond => VCondit Pres => VPres m
} ; } ;
vps = vp.s ! VPFinite tm a ; vps = vp.s ! VPFinite tm a ;
verb = vps.fin ! agr ; verb = vps.fin ! agr ;

View File

@@ -38,13 +38,15 @@ param
VFin = VFin =
VPres Voice VPres Voice
| VPret Voice | VPret Voice --# notpresent
| VImper Voice ; | VImper Voice
;
VInf = VInf =
VInfin Voice VInfin Voice
| VSupin Voice | VSupin Voice --# notpresent
| VPtPret AFormPos Case ; | VPtPret AFormPos Case
;
VPForm = VPForm =
VPFinite Tense Anteriority VPFinite Tense Anteriority
@@ -89,7 +91,7 @@ oper
vFin : Tense -> Voice -> VForm = \t,v -> case t of { vFin : Tense -> Voice -> VForm = \t,v -> case t of {
Pres => VF (VPres v) ; Pres => VF (VPres v) ;
Past => VF (VPret v) ; Past => VF (VPret v) ; --# notpresent
_ => VI (VInfin v) --- not to be used? _ => VI (VInfin v) --- not to be used?
} ; } ;
@@ -141,10 +143,10 @@ oper
s = table { s = table {
VF (VPres Act) => finner ; VF (VPres Act) => finner ;
VF (VPres Pass) => mkVoice Pass finn ; VF (VPres Pass) => mkVoice Pass finn ;
VF (VPret v) => mkVoice v fann ; VF (VPret v) => mkVoice v fann ; --# notpresent
VF (VImper v) => mkVoice v finn ; VF (VImper v) => mkVoice v finn ;
VI (VInfin v) => mkVoice v finna ; VI (VInfin v) => mkVoice v finna ;
VI (VSupin v) => mkVoice v funnit ; VI (VSupin v) => mkVoice v funnit ; --# notpresent
VI (VPtPret a c)=> mkCase c (mkAdjPos a funnen funnet funna funna) VI (VPtPret a c)=> mkCase c (mkAdjPos a funnen funnet funna funna)
} ; } ;
vtype = VAct vtype = VAct

View File

@@ -24,7 +24,7 @@ interface ResScand = DiffScand ** open CommonScand, Prelude in {
_ => Act _ => Act
} ; } ;
vfin : Tense -> Str = \t -> verb.s ! vFin t diath ; vfin : Tense -> Str = \t -> verb.s ! vFin t diath ;
vsup = verb.s ! VI (VSupin diath) ; vsup = verb.s ! VI (VSupin diath) ; --# notpresent
vinf = verb.s ! VI (VInfin diath) ; vinf = verb.s ! VI (VInfin diath) ;
har : Tense -> Str = \t -> verbHave.s ! vFin t Act ; har : Tense -> Str = \t -> verbHave.s ! vFin t Act ;
@@ -37,18 +37,20 @@ interface ResScand = DiffScand ** open CommonScand, Prelude in {
in { in {
s = table { s = table {
VPFinite t Simul => case t of { VPFinite t Simul => case t of {
Pres | Past => vf (vfin t) [] ; -- Pres | Past => vf (vfin t) [] ; -- the general rule
Fut => vf auxFut vinf ; Past => vf (vfin t) [] ; --# notpresent
Cond => vf auxCond vinf Fut => vf auxFut vinf ; --# notpresent
} ; Cond => vf auxCond vinf ; --# notpresent
VPFinite t Anter => case t of { Pres => vf (vfin t) []
Pres | Past => vf (har t) vsup ;
Fut => vf auxFut (ha ++ vsup) ;
Cond => vf auxCond (ha ++ vsup)
} ; } ;
VPFinite t Anter => case t of { --# notpresent
Pres | Past => vf (har t) vsup ; --# notpresent
Fut => vf auxFut (ha ++ vsup) ; --# notpresent
Cond => vf auxCond (ha ++ vsup) --# notpresent
} ; --# notpresent
VPImperat => vf (verb.s ! VF (VImper diath)) [] ; VPImperat => vf (verb.s ! VF (VImper diath)) [] ;
VPInfinit Simul => vf [] vinf ; VPInfinit Anter => vf [] (ha ++ vsup) ; --# notpresent
VPInfinit Anter => vf [] (ha ++ vsup) VPInfinit Simul => vf [] vinf
} ; } ;
a1 : Polarity => Str = negation ; a1 : Polarity => Str = negation ;
n2 : Agr => Str = \\a => case verb.vtype of { n2 : Agr => Str = \\a => case verb.vtype of {

File diff suppressed because it is too large Load Diff

View File

@@ -84,7 +84,7 @@ compileModule opts st0 file |
grammar1 <- case suff of grammar1 <- case suff of
"cf" -> putp ("- parsing" +++ suff +++ file) $ getCFGrammar opts file "cf" -> putp ("- parsing" +++ suff +++ file) $ getCFGrammar opts file
"ebnf" -> putp ("- parsing" +++ suff +++ file) $ getEBNFGrammar opts file "ebnf" -> putp ("- parsing" +++ suff +++ file) $ getEBNFGrammar opts file
"gfm" -> putp ("- parsing" +++ suff +++ file) $ getSourceGrammar file "gfm" -> putp ("- parsing" +++ suff +++ file) $ getSourceGrammar opts file
_ -> putp ("- parsing old gf" +++ file) $ getOldGrammar opts file _ -> putp ("- parsing old gf" +++ file) $ getOldGrammar opts file
let mods = modules grammar1 let mods = modules grammar1
let env = compileEnvShSt st0 [] let env = compileEnvShSt st0 []
@@ -195,7 +195,7 @@ compileOne opts env@((_,srcgr,_),_) file = do
-- for compiled resource, parse and organize, then update environment -- for compiled resource, parse and organize, then update environment
"gfr" -> do "gfr" -> do
sm0 <- putp ("| reading" +++ file) $ getSourceModule file sm0 <- putp ("| reading" +++ file) $ getSourceModule opts file
sm <- {- putp "creating indirections" $ -} ioeErr $ extendModule mos sm0 sm <- {- putp "creating indirections" $ -} ioeErr $ extendModule mos sm0
---- experiment with not optimizing gfr ---- experiment with not optimizing gfr
---- sm:_ <- putp " optimizing " $ ioeErr $ evalModule mos sm1 ---- sm:_ <- putp " optimizing " $ ioeErr $ evalModule mos sm1
@@ -206,7 +206,8 @@ compileOne opts env@((_,srcgr,_),_) file = do
-- for gf source, do full compilation -- for gf source, do full compilation
_ -> do _ -> do
sm0 <- putpOpt ("- parsing" +++ file) ("- compiling" +++ file ++ "... ") $ getSourceModule file sm0 <- putpOpt ("- parsing" +++ file) ("- compiling" +++ file ++ "... ") $
getSourceModule opts file
(k',sm) <- makeSourceModule opts (fst env) sm0 (k',sm) <- makeSourceModule opts (fst env) sm0
cm <- putpp " generating code... " $ generateModuleCode opts path sm cm <- putpp " generating code... " $ generateModuleCode opts path sm
ft <- getReadTimes file ft <- getReadTimes file

View File

@@ -44,16 +44,25 @@ import GF.Infra.ReadFiles ----
import Data.Char (toUpper) import Data.Char (toUpper)
import Data.List (nub) import Data.List (nub)
import Control.Monad (foldM) import Control.Monad (foldM)
import System (system)
getSourceModule :: FilePath -> IOE SourceModule getSourceModule :: Options -> FilePath -> IOE SourceModule
getSourceModule file = do getSourceModule opts file0 = do
file <- case getOptVal opts usePreprocessor of
Just p -> do
let tmp = "_gf_preproc.tmp"
cmd = p +++ file0 ++ ">" ++ tmp
ioeIO $ system cmd
-- ioeIO $ putStrLn $ "preproc" +++ cmd
return tmp
_ -> return file0
string <- readFileIOE file string <- readFileIOE file
let tokens = myLexer string let tokens = myLexer string
mo1 <- ioeErr $ {- err2err $ -} pModDef tokens mo1 <- ioeErr $ {- err2err $ -} pModDef tokens
ioeErr $ transModDef mo1 ioeErr $ transModDef mo1
getSourceGrammar :: FilePath -> IOE SourceGrammar getSourceGrammar :: Options -> FilePath -> IOE SourceGrammar
getSourceGrammar file = do getSourceGrammar opts file = do
string <- readFileIOE file string <- readFileIOE file
let tokens = myLexer string let tokens = myLexer string
gr1 <- ioeErr $ {- err2err $ -} pGrammar tokens gr1 <- ioeErr $ {- err2err $ -} pGrammar tokens

View File

@@ -313,6 +313,7 @@ pathList = aOpt "path"
uniCoding = aOpt "coding" uniCoding = aOpt "coding"
probFile = aOpt "probs" probFile = aOpt "probs"
noparseFile = aOpt "noparse" noparseFile = aOpt "noparse"
usePreprocessor = aOpt "preproc"
-- peb 16/3-05: -- peb 16/3-05:
gfcConversion :: String -> Option gfcConversion :: String -> Option

View File

@@ -74,6 +74,7 @@ txtHelpFile =
"\n -optimize select an optimization to override file-defined flags" ++ "\n -optimize select an optimization to override file-defined flags" ++
"\n -conversion select parsing method (values strict|nondet)" ++ "\n -conversion select parsing method (values strict|nondet)" ++
"\n -probs read probabilities from file (format (--# prob) Fun Double)" ++ "\n -probs read probabilities from file (format (--# prob) Fun Double)" ++
"\n -preproc use a preprocessor on each source file" ++
"\n -noparse read nonparsable functions from file (format --# noparse Funs) " ++ "\n -noparse read nonparsable functions from file (format --# noparse Funs) " ++
"\n examples:" ++ "\n examples:" ++
"\n i English.gf -- ordinary import of Concrete" ++ "\n i English.gf -- ordinary import of Concrete" ++

View File

@@ -170,7 +170,7 @@ optionsOfCommand co = case co of
"cat lang lexer parser number depth rawtrees unlexer optimize path conversion printer" "cat lang lexer parser number depth rawtrees unlexer optimize path conversion printer"
CImport _ -> both "old v s src gfc retain nocf nocheckcirc cflexer noemit o ex prob" CImport _ -> both "old v s src gfc retain nocf nocheckcirc cflexer noemit o ex prob"
"abs cnc res path optimize conversion cat probs noparse" "abs cnc res path optimize conversion cat preproc probs noparse"
CRemoveLanguage _ -> none CRemoveLanguage _ -> none
CEmptyState -> none CEmptyState -> none
CStripState -> none CStripState -> none

View File

@@ -45,6 +45,7 @@ i, import: i File
-optimize select an optimization to override file-defined flags -optimize select an optimization to override file-defined flags
-conversion select parsing method (values strict|nondet) -conversion select parsing method (values strict|nondet)
-probs read probabilities from file (format (--# prob) Fun Double) -probs read probabilities from file (format (--# prob) Fun Double)
-preproc use a preprocessor on each source file
-noparse read nonparsable functions from file (format --# noparse Funs) -noparse read nonparsable functions from file (format --# noparse Funs)
examples: examples:
i English.gf -- ordinary import of Concrete i English.gf -- ordinary import of Concrete