mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-04-23 19:42:50 -06:00
JEM tutorial examples - some files missing still
This commit is contained in:
34
examples/jem-math/Math.gf
Normal file
34
examples/jem-math/Math.gf
Normal file
@@ -0,0 +1,34 @@
|
||||
abstract Math = {
|
||||
|
||||
flags startcat = Prop ;
|
||||
|
||||
cat
|
||||
Prop ; Exp ;
|
||||
|
||||
fun
|
||||
And, Or, If : Prop -> Prop -> Prop ;
|
||||
|
||||
Zero : Exp ;
|
||||
|
||||
Successor : Exp -> Exp ;
|
||||
|
||||
Sum, Product : Exp -> Exp -> Exp ;
|
||||
|
||||
Even, Odd, Prime : Exp -> Prop ;
|
||||
|
||||
Equal, Less, Greater, Divisible : Exp -> Exp -> Prop ;
|
||||
|
||||
cat
|
||||
Var ;
|
||||
|
||||
fun
|
||||
X, Y : Var ;
|
||||
|
||||
EVar : Var -> Exp ;
|
||||
|
||||
EInt : Int -> Exp ;
|
||||
|
||||
ANumberVar : Var -> Exp ;
|
||||
TheNumberVar : Var -> Exp ;
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user