mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-05-06 17:52:51 -06:00
test set for resource started
This commit is contained in:
@@ -14,7 +14,7 @@ concrete AdverbEng of Adverb = CatEng ** open ResEng, Prelude in {
|
||||
AdAdv = cc2 ;
|
||||
|
||||
SubjS = cc2 ;
|
||||
AdvSC s = s ; --- this rule give stack overflow in ordinary parsing
|
||||
---b AdvSC s = s ; --- this rule give stack overflow in ordinary parsing
|
||||
|
||||
AdnCAdv cadv = {s = cadv.s ++ "than"} ;
|
||||
|
||||
|
||||
@@ -26,6 +26,7 @@ concrete CatEng of Cat = CommonX ** open ResEng, Prelude in {
|
||||
IP = {s : Case => Str ; n : Number} ;
|
||||
IComp = {s : Str} ;
|
||||
IDet = {s : Str ; n : Number} ;
|
||||
IQuant = {s : Number => Str} ;
|
||||
|
||||
-- Relative
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@ concrete IdiomEng of Idiom = CatEng ** open Prelude, ResEng in {
|
||||
(insertObj (\\_ => np.s ! rs.c) (predAux auxBe))) ;
|
||||
|
||||
CleftAdv ad s = mkClause "it" (agrP3 Sg)
|
||||
(insertObj (\\_ => conjThat ++ s.s)
|
||||
(insertObj (\\_ => optStr conjThat ++ s.s)
|
||||
(insertObj (\\_ => ad.s) (predAux auxBe))) ;
|
||||
|
||||
ExistNP np =
|
||||
|
||||
@@ -130,7 +130,7 @@ lin
|
||||
open_V2 = dirV2 (regV "open") ;
|
||||
paint_V2A = mkV2A (regV "paint") noPrep ;
|
||||
paper_N = regN "paper" ;
|
||||
paris_PN = regPN "Paris" ;
|
||||
paris_PN = mkPN (mkN nonhuman (mkN "Paris")) ;
|
||||
peace_N = regN "peace" ;
|
||||
pen_N = regN "pen" ;
|
||||
planet_N = regN "planet" ;
|
||||
|
||||
@@ -99,7 +99,19 @@ concrete NounEng of Noun = CatEng ** open ResEng, Prelude in {
|
||||
|
||||
UseN n = n ;
|
||||
UseN2 n = n ;
|
||||
UseN3 n = n ;
|
||||
---b UseN3 n = n ;
|
||||
|
||||
Use2N3 f = {
|
||||
s = \\n,c => f.s ! n ! Nom ;
|
||||
g = f.g ;
|
||||
c2 = f.c2
|
||||
} ;
|
||||
|
||||
Use3N3 f = {
|
||||
s = \\n,c => f.s ! n ! Nom ;
|
||||
g = f.g ;
|
||||
c2 = f.c3
|
||||
} ;
|
||||
|
||||
ComplN2 f x = {s = \\n,c => f.s ! n ! Nom ++ f.c2 ++ x.s ! c ; g = f.g} ;
|
||||
ComplN3 f x = {
|
||||
|
||||
@@ -27,18 +27,29 @@ concrete QuestionEng of Question = CatEng ** open ResEng, Prelude in {
|
||||
mkQuestion icomp (mkClause (np.s ! Nom) np.a (predAux auxBe)) ;
|
||||
|
||||
|
||||
PrepIP p ip = {s = p.s ++ ip.s ! Nom} ;
|
||||
PrepIP p ip = {s = p.s ++ ip.s ! Acc} ;
|
||||
|
||||
AdvIP ip adv = {
|
||||
s = \\c => ip.s ! c ++ adv.s ;
|
||||
n = ip.n
|
||||
} ;
|
||||
|
||||
IDetCN idet num ord cn = {
|
||||
s = \\c => idet.s ++ num.s ++ ord.s ++ cn.s ! idet.n ! c ;
|
||||
IdetCN idet cn = {
|
||||
s = \\c => idet.s ++ cn.s ! idet.n ! c ;
|
||||
n = idet.n
|
||||
} ;
|
||||
|
||||
IdetIP idet = {
|
||||
s = \\c => idet.s ;
|
||||
n = idet.n
|
||||
} ;
|
||||
|
||||
IdetQuant idet num = {
|
||||
s = idet.s ! num.n ++ num.s ;
|
||||
n = num.n
|
||||
} ;
|
||||
|
||||
CompIAdv a = a ;
|
||||
CompIP p = ss (p.s ! Nom) ;
|
||||
|
||||
}
|
||||
|
||||
@@ -105,8 +105,9 @@ concrete StructuralEng of Structural = CatEng **
|
||||
when_IAdv = ss "when" ;
|
||||
when_Subj = ss "when" ;
|
||||
where_IAdv = ss "where" ;
|
||||
whichPl_IDet = mkDeterminer Pl ["which"] ;
|
||||
whichSg_IDet = mkDeterminer Sg ["which"] ;
|
||||
which_IQuant = {s = \\_ => "which"} ;
|
||||
---b whichPl_IDet = mkDeterminer Pl ["which"] ;
|
||||
---b whichSg_IDet = mkDeterminer Sg ["which"] ;
|
||||
whoSg_IP = mkIP "who" "whom" "whose" Sg ;
|
||||
whoPl_IP = mkIP "who" "whom" "whose" Pl ;
|
||||
why_IAdv = ss "why" ;
|
||||
|
||||
Reference in New Issue
Block a user