From e9e80fc389365e24d4300d7d5390c7d833a96c50 Mon Sep 17 00:00:00 2001 From: aarne Date: Wed, 25 Jun 2008 16:54:35 +0000 Subject: changed names of resource-1.3; added a note on homepage on release --- old-examples/tutorial/smart/SmartI.gf | 50 +++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 old-examples/tutorial/smart/SmartI.gf (limited to 'old-examples/tutorial/smart/SmartI.gf') diff --git a/old-examples/tutorial/smart/SmartI.gf b/old-examples/tutorial/smart/SmartI.gf new file mode 100644 index 000000000..2b46ba0fe --- /dev/null +++ b/old-examples/tutorial/smart/SmartI.gf @@ -0,0 +1,50 @@ +--# -path=.:present:prelude + +incomplete concrete SmartI of Smart = open Syntax, LexSmart, Prelude in { + +-- grammar Toy1 from the Regulus book + +flags startcat = Utterance ; + +lincat + Utterance = Utt ; + Command = Imp ; + Question = QS ; + Kind = N ; + Action = V2 ; + Device = NP ; + Location = N ; + +lin + UCommand c = mkUtt politeImpForm c ; + UQuestion q = mkUtt q ; + + CAction _ act dev = mkImp act dev ; + QAction _ act st dev = + mkQS anteriorAnt (mkQCl (mkCl dev (passiveVP act))) ; ---- show empty proof + + DKindOne k = mkNP defSgDet k ; + DKindMany k = mkNP defPlDet k ; + DLoc _ dev loc = mkNP dev (mkAdv in_Prep (mkNP defSgDet loc)) ; + + light = light_N ; + fan = fan_N ; + + switchOn _ _ = switchOn_V2 ; + switchOff _ _ = switchOff_V2 ; + + dim _ _ = dim_V2 ; + + kitchen = kitchen_N ; + livingRoom = livingRoom_N ; + +lin + switchable_light = ss [] ; + switchable_fan = ss [] ; + dimmable_light = ss [] ; + + statelike_switchOn _ _ = ss [] ; + statelike_switchOff _ _ = ss [] ; + + +} -- cgit v1.2.3