summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authoraarne <aarne@cs.chalmers.se>2007-10-12 13:46:57 +0000
committeraarne <aarne@cs.chalmers.se>2007-10-12 13:46:57 +0000
commit96ed0bf4ac7e2898f6f8de82cacecb69d1e94684 (patch)
treeff4759c241902dabc0198fafcfe76943bf52b328 /examples
parent530174aad1d5afecd050a5fe9be83d73e14b2d2a (diff)
demo restaurant info
Diffstat (limited to 'examples')
-rw-r--r--examples/restaurant/LexRestaurant.gf8
-rw-r--r--examples/restaurant/LexRestaurantEng.gf12
-rw-r--r--examples/restaurant/LexRestaurantFin.gf12
-rw-r--r--examples/restaurant/LexRestaurantGer.gf12
-rw-r--r--examples/restaurant/LexRestaurantSwe.gf12
-rw-r--r--examples/restaurant/Restaurant.gf19
-rw-r--r--examples/restaurant/RestaurantEng.gf5
-rw-r--r--examples/restaurant/RestaurantFin.gf5
-rw-r--r--examples/restaurant/RestaurantGer.gf5
-rw-r--r--examples/restaurant/RestaurantI.gf21
-rw-r--r--examples/restaurant/RestaurantSwe.gf5
11 files changed, 116 insertions, 0 deletions
diff --git a/examples/restaurant/LexRestaurant.gf b/examples/restaurant/LexRestaurant.gf
new file mode 100644
index 000000000..fc25d2080
--- /dev/null
+++ b/examples/restaurant/LexRestaurant.gf
@@ -0,0 +1,8 @@
+interface LexRestaurant = open Syntax in {
+
+oper
+ restaurant_N : N ;
+ cheap_A : A ;
+ italian_A, thai_A, swedish_A, french_A : A ;
+ konkanok_PN : PN ;
+}
diff --git a/examples/restaurant/LexRestaurantEng.gf b/examples/restaurant/LexRestaurantEng.gf
new file mode 100644
index 000000000..029144565
--- /dev/null
+++ b/examples/restaurant/LexRestaurantEng.gf
@@ -0,0 +1,12 @@
+instance LexRestaurantEng of LexRestaurant = open SyntaxEng, ParadigmsEng in {
+
+oper
+ restaurant_N = mkN "restaurant" ;
+ cheap_A = mkA "cheap" ;
+ italian_A = mkA "Italian" ;
+ thai_A = mkA "Thai" ;
+ swedish_A = mkA "Swedish" ;
+ french_A = mkA "French" ;
+
+ konkanok_PN = mkPN "Konkanok" ;
+}
diff --git a/examples/restaurant/LexRestaurantFin.gf b/examples/restaurant/LexRestaurantFin.gf
new file mode 100644
index 000000000..1755faa5e
--- /dev/null
+++ b/examples/restaurant/LexRestaurantFin.gf
@@ -0,0 +1,12 @@
+instance LexRestaurantFin of LexRestaurant = open SyntaxFin, ParadigmsFin in {
+
+oper
+ restaurant_N = mkN "ravintola" ;
+ cheap_A = mkA "halpa" ;
+ italian_A = mkA "italialainen" ;
+ thai_A = mkA "thaimaalainen" ;
+ swedish_A = mkA "ruotsalainen" ;
+ french_A = mkA "ranskalainen" ;
+
+ konkanok_PN = mkPN "Konkanok" ;
+}
diff --git a/examples/restaurant/LexRestaurantGer.gf b/examples/restaurant/LexRestaurantGer.gf
new file mode 100644
index 000000000..349a11fd7
--- /dev/null
+++ b/examples/restaurant/LexRestaurantGer.gf
@@ -0,0 +1,12 @@
+instance LexRestaurantGer of LexRestaurant = open SyntaxGer, ParadigmsGer in {
+
+oper
+ restaurant_N = mkN "Restaurant" "Restaurants" neuter ;
+ cheap_A = mkA "billig" ;
+ italian_A = mkA "italienisch" ;
+ thai_A = mkA "thailändisch" ;
+ swedish_A = mkA "schwedisch" ;
+ french_A = mkA "französisch" ;
+
+ konkanok_PN = mkPN "Konkanok" ;
+}
diff --git a/examples/restaurant/LexRestaurantSwe.gf b/examples/restaurant/LexRestaurantSwe.gf
new file mode 100644
index 000000000..57d4e0487
--- /dev/null
+++ b/examples/restaurant/LexRestaurantSwe.gf
@@ -0,0 +1,12 @@
+instance LexRestaurantSwe of LexRestaurant = open SyntaxSwe, ParadigmsSwe in {
+
+oper
+ restaurant_N = mkN "restaurang" ;
+ cheap_A = mkA "billig" ;
+ italian_A = mkA "italiensk" ;
+ thai_A = mkA "thailändsk" ;
+ swedish_A = mkA "svensk" ;
+ french_A = mkA "fransk" ;
+
+ konkanok_PN = mkPN "Konkanok" ;
+}
diff --git a/examples/restaurant/Restaurant.gf b/examples/restaurant/Restaurant.gf
new file mode 100644
index 000000000..7b0a586de
--- /dev/null
+++ b/examples/restaurant/Restaurant.gf
@@ -0,0 +1,19 @@
+abstract Restaurant = {
+
+flags startcat = Descr ;
+
+cat
+ Descr ;
+ Name ;
+ Nationality ;
+ PriceLevel ;
+
+fun
+ MkDescr : Name -> PriceLevel -> Nationality -> Descr ;
+
+ Cheap : PriceLevel ;
+ Italian, Thai, Swedish, French : Nationality ;
+ Konkanok : Name ;
+
+
+}
diff --git a/examples/restaurant/RestaurantEng.gf b/examples/restaurant/RestaurantEng.gf
new file mode 100644
index 000000000..a6440219a
--- /dev/null
+++ b/examples/restaurant/RestaurantEng.gf
@@ -0,0 +1,5 @@
+--# -path=.:present:prelude
+
+concrete RestaurantEng of Restaurant = RestaurantI with
+ (Syntax = SyntaxEng),
+ (LexRestaurant = LexRestaurantEng) ;
diff --git a/examples/restaurant/RestaurantFin.gf b/examples/restaurant/RestaurantFin.gf
new file mode 100644
index 000000000..18aa08ced
--- /dev/null
+++ b/examples/restaurant/RestaurantFin.gf
@@ -0,0 +1,5 @@
+--# -path=.:present:prelude
+
+concrete RestaurantFin of Restaurant = RestaurantI with
+ (Syntax = SyntaxFin),
+ (LexRestaurant = LexRestaurantFin) ;
diff --git a/examples/restaurant/RestaurantGer.gf b/examples/restaurant/RestaurantGer.gf
new file mode 100644
index 000000000..af711766c
--- /dev/null
+++ b/examples/restaurant/RestaurantGer.gf
@@ -0,0 +1,5 @@
+--# -path=.:present:prelude
+
+concrete RestaurantGer of Restaurant = RestaurantI with
+ (Syntax = SyntaxGer),
+ (LexRestaurant = LexRestaurantGer) ;
diff --git a/examples/restaurant/RestaurantI.gf b/examples/restaurant/RestaurantI.gf
new file mode 100644
index 000000000..c84a738ce
--- /dev/null
+++ b/examples/restaurant/RestaurantI.gf
@@ -0,0 +1,21 @@
+incomplete concrete RestaurantI of Restaurant = open Syntax, LexRestaurant in {
+
+lincat
+ Descr = Phr ;
+ Name = NP ;
+ Nationality = A ;
+ PriceLevel = A ;
+
+lin
+ MkDescr name price nat =
+ mkPhr (mkCl name (mkNP indefSgDet (mkCN price (mkCN nat (mkCN restaurant_N))))) ;
+
+ Cheap = cheap_A ;
+ Italian = italian_A ;
+ Thai = thai_A ;
+ Swedish = swedish_A ;
+ French = french_A ;
+ Konkanok = mkNP konkanok_PN ;
+
+
+}
diff --git a/examples/restaurant/RestaurantSwe.gf b/examples/restaurant/RestaurantSwe.gf
new file mode 100644
index 000000000..a8081b7f1
--- /dev/null
+++ b/examples/restaurant/RestaurantSwe.gf
@@ -0,0 +1,5 @@
+--# -path=.:present:prelude
+
+concrete RestaurantSwe of Restaurant = RestaurantI with
+ (Syntax = SyntaxSwe),
+ (LexRestaurant = LexRestaurantSwe) ;