mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-04-23 03:32:51 -06:00
parsable demo of resource, without VP
This commit is contained in:
@@ -67,7 +67,7 @@ make xx = do
|
|||||||
gfc pres path file = do
|
gfc pres path file = do
|
||||||
let preproc = if pres then " -preproc=./mkPresent " else ""
|
let preproc = if pres then " -preproc=./mkPresent " else ""
|
||||||
putStrLn $ "compiling " ++ file
|
putStrLn $ "compiling " ++ file
|
||||||
system $ "gfc -s " ++ preproc ++ path ++ file
|
system $ "gfc -s -src " ++ preproc ++ path ++ file
|
||||||
|
|
||||||
gf comm file = do
|
gf comm file = do
|
||||||
putStrLn $ "reading " ++ file
|
putStrLn $ "reading " ++ file
|
||||||
|
|||||||
9
lib/resource-1.4/demo/Clause.gf
Normal file
9
lib/resource-1.4/demo/Clause.gf
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
abstract Clause = Cat ** {
|
||||||
|
|
||||||
|
fun
|
||||||
|
PredV : NP -> V -> Cl ;
|
||||||
|
PredV2 : NP -> V2 -> NP -> Cl ;
|
||||||
|
PredAP : NP -> AP -> Cl ;
|
||||||
|
PredAdv : NP -> Adv -> Cl ;
|
||||||
|
|
||||||
|
}
|
||||||
1
lib/resource-1.4/demo/ClauseEng.gf
Normal file
1
lib/resource-1.4/demo/ClauseEng.gf
Normal file
@@ -0,0 +1 @@
|
|||||||
|
concrete ClauseEng of Clause = CatEng ** ClauseI with (Grammar = GrammarEng) ;
|
||||||
1
lib/resource-1.4/demo/ClauseFin.gf
Normal file
1
lib/resource-1.4/demo/ClauseFin.gf
Normal file
@@ -0,0 +1 @@
|
|||||||
|
concrete ClauseFin of Clause = CatFin ** ClauseI with (Grammar = GrammarFin) ;
|
||||||
1
lib/resource-1.4/demo/ClauseFre.gf
Normal file
1
lib/resource-1.4/demo/ClauseFre.gf
Normal file
@@ -0,0 +1 @@
|
|||||||
|
concrete ClauseFre of Clause = CatFre ** ClauseI with (Grammar = GrammarFre) ;
|
||||||
1
lib/resource-1.4/demo/ClauseGer.gf
Normal file
1
lib/resource-1.4/demo/ClauseGer.gf
Normal file
@@ -0,0 +1 @@
|
|||||||
|
concrete ClauseGer of Clause = CatGer ** ClauseI with (Grammar = GrammarGer) ;
|
||||||
9
lib/resource-1.4/demo/ClauseI.gf
Normal file
9
lib/resource-1.4/demo/ClauseI.gf
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
incomplete concrete ClauseI of Clause = Cat ** open Grammar in {
|
||||||
|
|
||||||
|
lin
|
||||||
|
PredV np v = PredVP np (UseV v) ;
|
||||||
|
PredV2 s v o = PredVP s (ComplSlash (SlashV2a v) o) ;
|
||||||
|
PredAP s a = PredVP s (UseComp (CompAP a)) ;
|
||||||
|
PredAdv s a = PredVP s (UseComp (CompAdv a)) ;
|
||||||
|
|
||||||
|
}
|
||||||
17
lib/resource-1.4/demo/Demo.gf
Normal file
17
lib/resource-1.4/demo/Demo.gf
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
abstract Demo =
|
||||||
|
Noun- [AdvCN],
|
||||||
|
-- Verb,
|
||||||
|
Clause, --
|
||||||
|
Adjective,
|
||||||
|
Adverb,
|
||||||
|
Numeral,
|
||||||
|
---- Sentence,
|
||||||
|
---- Question,
|
||||||
|
---- Relative,
|
||||||
|
---- Conjunction,
|
||||||
|
---- Phrase,
|
||||||
|
---- Text,
|
||||||
|
---- Idiom,
|
||||||
|
Structural,
|
||||||
|
Lexicon ;
|
||||||
|
|
||||||
23
lib/resource-1.4/demo/DemoEng.gf
Normal file
23
lib/resource-1.4/demo/DemoEng.gf
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
--# -path=.:alltenses
|
||||||
|
|
||||||
|
concrete DemoEng of Demo =
|
||||||
|
NounEng - [AdvCN],
|
||||||
|
-- VerbEng,
|
||||||
|
ClauseEng, --
|
||||||
|
AdjectiveEng,
|
||||||
|
AdverbEng,
|
||||||
|
NumeralEng,
|
||||||
|
SentenceEng,
|
||||||
|
QuestionEng,
|
||||||
|
RelativeEng,
|
||||||
|
ConjunctionEng,
|
||||||
|
PhraseEng,
|
||||||
|
TextX,
|
||||||
|
StructuralEng,
|
||||||
|
IdiomEng,
|
||||||
|
LexiconEng
|
||||||
|
** {
|
||||||
|
|
||||||
|
flags startcat = Phr ; unlexer = text ; lexer = text ;
|
||||||
|
|
||||||
|
} ;
|
||||||
23
lib/resource-1.4/demo/DemoFin.gf
Normal file
23
lib/resource-1.4/demo/DemoFin.gf
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
--# -path=.:alltenses
|
||||||
|
|
||||||
|
concrete DemoFin of Demo =
|
||||||
|
NounFin - [AdvCN],
|
||||||
|
-- VerbFin,
|
||||||
|
ClauseFin, --
|
||||||
|
AdjectiveFin,
|
||||||
|
AdverbFin,
|
||||||
|
NumeralFin,
|
||||||
|
---- SentenceFin,
|
||||||
|
---- QuestionFin,
|
||||||
|
---- RelativeFin,
|
||||||
|
---- ConjunctionFin,
|
||||||
|
---- PhraseFin,
|
||||||
|
---- TextX,
|
||||||
|
---- IdiomFin,
|
||||||
|
StructuralFin,
|
||||||
|
LexiconFin
|
||||||
|
** {
|
||||||
|
|
||||||
|
flags startcat = Phr ; unlexer = text ; lexer = text ;
|
||||||
|
|
||||||
|
} ;
|
||||||
23
lib/resource-1.4/demo/DemoFre.gf
Normal file
23
lib/resource-1.4/demo/DemoFre.gf
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
--# -path=.:alltenses
|
||||||
|
|
||||||
|
concrete DemoFre of Demo =
|
||||||
|
NounFre - [AdvCN],
|
||||||
|
-- VerbFre,
|
||||||
|
ClauseFre, --
|
||||||
|
AdjectiveFre,
|
||||||
|
AdverbFre,
|
||||||
|
NumeralFre,
|
||||||
|
---- SentenceFre,
|
||||||
|
---- QuestionFre,
|
||||||
|
---- RelativeFre,
|
||||||
|
---- ConjunctionFre,
|
||||||
|
---- PhraseFre,
|
||||||
|
---- TextX - [Tense,TPres,TPast,TFut,TCond],
|
||||||
|
---- IdiomFre,
|
||||||
|
StructuralFre,
|
||||||
|
LexiconFre
|
||||||
|
** {
|
||||||
|
|
||||||
|
flags startcat = Phr ; unlexer = text ; lexer = text ;
|
||||||
|
|
||||||
|
} ;
|
||||||
23
lib/resource-1.4/demo/DemoGer.gf
Normal file
23
lib/resource-1.4/demo/DemoGer.gf
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
--# -path=.:alltenses
|
||||||
|
|
||||||
|
concrete DemoGer of Demo =
|
||||||
|
NounGer - [AdvCN],
|
||||||
|
-- VerbGer,
|
||||||
|
ClauseGer, --
|
||||||
|
AdjectiveGer,
|
||||||
|
AdverbGer,
|
||||||
|
NumeralGer,
|
||||||
|
-- SentenceGer,
|
||||||
|
-- QuestionGer,
|
||||||
|
-- RelativeGer,
|
||||||
|
-- ConjunctionGer,
|
||||||
|
-- PhraseGer,
|
||||||
|
-- TextX - [Tense,TPres,TPast,TFut,TCond],
|
||||||
|
-- IdiomGer,
|
||||||
|
StructuralGer,
|
||||||
|
LexiconGer
|
||||||
|
** {
|
||||||
|
|
||||||
|
flags startcat = Phr ; unlexer = text ; lexer = text ;
|
||||||
|
|
||||||
|
} ;
|
||||||
23
lib/resource-1.4/demo/DemoI.gf
Normal file
23
lib/resource-1.4/demo/DemoI.gf
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
--# -path=.:alltenses
|
||||||
|
|
||||||
|
concrete DemoEng of Demo =
|
||||||
|
NounEng - [AdvCN],
|
||||||
|
-- VerbEng,
|
||||||
|
ClauseEng, --
|
||||||
|
AdjectiveEng,
|
||||||
|
AdverbEng,
|
||||||
|
NumeralEng,
|
||||||
|
SentenceEng,
|
||||||
|
QuestionEng,
|
||||||
|
RelativeEng,
|
||||||
|
ConjunctionEng,
|
||||||
|
PhraseEng,
|
||||||
|
TextX,
|
||||||
|
StructuralEng,
|
||||||
|
IdiomEng,
|
||||||
|
LexiconEng
|
||||||
|
** {
|
||||||
|
|
||||||
|
flags startcat = Phr ; unlexer = text ; lexer = text ;
|
||||||
|
|
||||||
|
} ;
|
||||||
Reference in New Issue
Block a user