mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-04-09 04:59:31 -06:00
extended Attempto with some constructs
This commit is contained in:
@@ -1,11 +1,12 @@
|
||||
abstract Attempto = Symbols ** {
|
||||
abstract Attempto =
|
||||
Numeral, Symbols ** {
|
||||
|
||||
flags startcat = ACEText ;
|
||||
|
||||
cat CN ;
|
||||
cat NP ;
|
||||
cat Card ;
|
||||
cat Numeral ;
|
||||
---cat Numeral ;
|
||||
cat PN ;
|
||||
cat A ;
|
||||
cat A2 ;
|
||||
@@ -54,10 +55,10 @@ fun noMassNP : MCN -> NP ;
|
||||
fun allMassNP : MCN -> NP ;
|
||||
fun notAllMassNP : MCN -> NP ;
|
||||
|
||||
fun one_Card : Card ;
|
||||
fun two_Card : Card ;
|
||||
fun five_Card : Card ;
|
||||
fun ten_Card : Card ;
|
||||
---fun one_Card : Card ;
|
||||
---fun two_Card : Card ;
|
||||
---fun five_Card : Card ;
|
||||
---fun ten_Card : Card ;
|
||||
|
||||
|
||||
fun pnNP : PN -> NP ;
|
||||
@@ -234,7 +235,7 @@ fun whoseIP : CN -> IP ; -- whose dog
|
||||
|
||||
-- 3.6
|
||||
|
||||
fun impVP : NP -> VP -> Text ; -- John, go to the bank!
|
||||
fun np_impVP : NP -> VP -> Text ; -- John, go to the bank!
|
||||
|
||||
-- 4
|
||||
|
||||
@@ -246,6 +247,14 @@ fun baseText : Text -> ACEText ;
|
||||
fun sText : S -> Text ;
|
||||
fun qsText : QS -> Text ;
|
||||
|
||||
-- more
|
||||
|
||||
fun npVP : NP -> VP ; -- is a bank
|
||||
fun impVP : VP -> Text ; -- go to the bank!
|
||||
fun numeralCard : Numeral -> Card ; -- fifteen banks
|
||||
fun digitsCard : Digits -> Card ; -- 8 banks
|
||||
fun have_V2 : V2 ; -- has (an apple)
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--# -path=.:present
|
||||
|
||||
concrete AttemptoEng of Attempto = SymbolsC ** AttemptoI with
|
||||
concrete AttemptoEng of Attempto = SymbolsC,NumeralEng ** AttemptoI with
|
||||
(Syntax = SyntaxEng),
|
||||
(Symbolic = SymbolicEng),
|
||||
(LexAttempto = LexAttemptoEng) ;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--# -path=.:present
|
||||
|
||||
concrete AttemptoFin of Attempto = SymbolsC ** AttemptoI with
|
||||
concrete AttemptoFin of Attempto = NumeralFin, SymbolsC ** AttemptoI with
|
||||
(Syntax = SyntaxFin),
|
||||
(Symbolic = SymbolicFin),
|
||||
(LexAttempto = LexAttemptoFin) ;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--# -path=.:present
|
||||
|
||||
concrete AttemptoFre of Attempto = SymbolsC ** AttemptoI with
|
||||
concrete AttemptoFre of Attempto = NumeralFre, SymbolsC ** AttemptoI with
|
||||
(Syntax = SyntaxFre),
|
||||
(Symbolic = SymbolicFre),
|
||||
(LexAttempto = LexAttemptoFre) ;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--# -path=.:/Users/aarne/GF/next-lib/present
|
||||
|
||||
concrete AttemptoGer of Attempto = SymbolsC ** AttemptoI with
|
||||
concrete AttemptoGer of Attempto = SymbolsC, NumeralGer ** AttemptoI with
|
||||
(Syntax = SyntaxGer),
|
||||
(Symbolic = SymbolicGer),
|
||||
(LexAttempto = LexAttemptoGer) ;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
incomplete concrete AttemptoI of Attempto = SymbolsC ** open
|
||||
incomplete concrete AttemptoI of Attempto = SymbolsC, Numeral ** open
|
||||
Syntax,
|
||||
Symbolic,
|
||||
Prelude,
|
||||
@@ -8,7 +8,7 @@ in {
|
||||
lincat CN = Syntax.CN ;
|
||||
lincat NP = Syntax.NP ;
|
||||
lincat Card = Syntax.Card ;
|
||||
lincat Numeral = Syntax.Numeral ;
|
||||
--lincat Numeral = Syntax.Numeral ;
|
||||
lincat PN = Syntax.PN ;
|
||||
lincat A = Syntax.A ;
|
||||
lincat A2 = Syntax.A2 ;
|
||||
@@ -32,7 +32,7 @@ lincat ACEText = Syntax.Text ;
|
||||
lincat RP = Syntax.RP ;
|
||||
|
||||
lincat MCN = Syntax.CN ;
|
||||
lincat PP = Adv ;
|
||||
lincat PP = Syntax.Adv ;
|
||||
|
||||
lin aNP = mkNP a_Art ;
|
||||
lin theNP = mkNP the_Art ;
|
||||
@@ -57,10 +57,10 @@ lin allMassNP cn = mkNP all_Predet (mkNP cn) ;
|
||||
lin noMassNP = mkNP no_Quant ;
|
||||
lin notAllMassNP cn = mkNP not_Predet (mkNP all_Predet (mkNP cn)) ;
|
||||
|
||||
lin one_Card = mkCard n1_Numeral ;
|
||||
lin two_Card = mkCard n2_Numeral ;
|
||||
lin five_Card = mkCard n5_Numeral ;
|
||||
lin ten_Card = mkCard n10_Numeral ;
|
||||
---lin one_Card = mkCard n1_Numeral ;
|
||||
---lin two_Card = mkCard n2_Numeral ;
|
||||
---lin five_Card = mkCard n5_Numeral ;
|
||||
---lin ten_Card = mkCard n10_Numeral ;
|
||||
|
||||
lin pnNP = mkNP ;
|
||||
lin intNP = symb ;
|
||||
@@ -159,7 +159,6 @@ lin more_thanVP ap np = mkVP (mkAP more_CAdv ap np) ;
|
||||
---- John is as fond-of Mary as of Sue
|
||||
---- John is more fond-of Mary than of Sue
|
||||
|
||||
lincat PP = Adv ;
|
||||
--lincat [PP] = Adv ;
|
||||
|
||||
--lin BasePP p = p ;
|
||||
@@ -235,7 +234,7 @@ lin whoseIP = mkIP whose_IDet ;
|
||||
|
||||
-- 3.6
|
||||
|
||||
lin impVP np vp = mkText (mkPhr (mkUtt (mkImp vp)) (mkVoc np)) exclMarkPunct ;
|
||||
lin np_impVP np vp = mkText (mkPhr (mkUtt (mkImp vp)) (mkVoc np)) exclMarkPunct ;
|
||||
---- John, go to the bank!
|
||||
|
||||
|
||||
@@ -244,6 +243,15 @@ lin baseText t = t ;
|
||||
lin sText = mkText ;
|
||||
lin qsText = mkText ;
|
||||
|
||||
|
||||
--- more
|
||||
|
||||
lin npVP = mkVP ;
|
||||
lin impVP vp = mkText (mkImp vp) ;
|
||||
lin numeralCard n = mkCard <lin Numeral n : Numeral> ;
|
||||
lin digitsCard n = mkCard <lin Digits n : Digits> ;
|
||||
lin have_V2 = Syntax.have_V2 ;
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--# -path=.:present
|
||||
|
||||
concrete AttemptoIta of Attempto = SymbolsC ** AttemptoI with
|
||||
concrete AttemptoIta of Attempto = NumeralIta, SymbolsC ** AttemptoI with
|
||||
(Syntax = SyntaxIta),
|
||||
(Symbolic = SymbolicIta),
|
||||
(LexAttempto = LexAttemptoIta) ;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--# -path=.:present
|
||||
|
||||
concrete AttemptoSwe of Attempto = SymbolsC ** AttemptoI with
|
||||
concrete AttemptoSwe of Attempto = NumeralSwe, SymbolsC ** AttemptoI with
|
||||
(Syntax = SyntaxSwe),
|
||||
(Symbolic = SymbolicSwe),
|
||||
(LexAttempto = LexAttemptoSwe) ;
|
||||
|
||||
Reference in New Issue
Block a user