forked from GitHub/gf-core
gf-book web page index and toc
This commit is contained in:
10
gf-book/examples/chapter8/CalculatorC.gf
Normal file
10
gf-book/examples/chapter8/CalculatorC.gf
Normal file
@@ -0,0 +1,10 @@
|
||||
concrete CalculatorC of Calculator = open Formal, Prelude in {
|
||||
lincat
|
||||
Exp = TermPrec ;
|
||||
lin
|
||||
EPlus = infixl 0 "+" ;
|
||||
EMinus = infixl 0 "-" ;
|
||||
ETimes = infixl 1 "*" ;
|
||||
EDiv = infixl 1 "/" ;
|
||||
EInt i = constant i.s ;
|
||||
}
|
||||
Reference in New Issue
Block a user