Skip to content

Instantly share code, notes, and snippets.

@UnkindPartition
Created March 11, 2014 17:41
Show Gist options
  • Save UnkindPartition/9490950 to your computer and use it in GitHub Desktop.
Save UnkindPartition/9490950 to your computer and use it in GitHub Desktop.
abstract Simple = {
flags startcat = Object;
cat Object; Quality;
fun
Meal, Drink: Object;
Tasty, Exotic: Quality;
QObject: Quality -> Object -> Object;
And: Object -> Object -> Object;
}
concrete SimpleUk of Simple = {
flags lexer=text;
lincat Object, Quality = {s: Str};
lin Meal = {s = "страви"};
lin Drink = {s = "напої"};
lin Tasty = {s = "смачні"};
lin Exotic = {s = "екзотичні"};
lin QObject qual obj = {s = qual.s ++ obj.s};
lin And ob1 ob2 = {s = ob1.s ++ ("та"|",") ++ ob2.s};
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment