Added Eclipse contents

This commit is contained in:
john.j.camilleri
2011-10-17 16:01:07 +00:00
parent 96547fd26f
commit 8854cb943a
27 changed files with 166 additions and 0 deletions

View File

@@ -0,0 +1,5 @@
abstract AbsCat = {
cat Greeting ; Recipient ;
};

View File

@@ -0,0 +1,12 @@
abstract HelloAbs = AbsCat [Greeting, Recipient] ** {
flags startcat = Greeting ;
cat Farewell ;
fun
Hello : Recipient -> Greeting ;
Goodbye : Recipient -> Farewell ;
World, Parent, Friends : Recipient ;
}

View File

@@ -0,0 +1,21 @@
concrete HelloEng of HelloAbs = ResEng ** {
lincat
Greeting, Farewell = {s : Str} ;
Recipient = {s : Gender => Str} ;
lin
Hello recip = {s = "hello" ++ recip.s ! Masc} ;
Goodbye recip = {s = "goodbye" ++ recip.s ! Fem} ;
World = {s = \\_ => "world"} ;
Parent = { s = table {
Masc => "dad" ; Fem => "mum"
} } ;
Friends = superate "friends" ;
oper
superate : Str -> Recipient = \s ->
lin Recipient { s = \\_ => "super" ++ s } ;
}

View File

@@ -0,0 +1,8 @@
--# -path=.:../abstract:../common:../../prelude
resource ResEng = {
param
OtherParam = A | B ;
Gender = Masc | Fem ;
} ;