From e2b9657f79d913dddb064037e79a9dd1a63bdbf9 Mon Sep 17 00:00:00 2001 From: aarne Date: Tue, 4 Sep 2007 20:51:26 +0000 Subject: cleaned up Calculator example --- examples/tutorial/calculator/Calculator.gf | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'examples/tutorial/calculator/Calculator.gf') diff --git a/examples/tutorial/calculator/Calculator.gf b/examples/tutorial/calculator/Calculator.gf index c2fbcd1bc..65192e226 100644 --- a/examples/tutorial/calculator/Calculator.gf +++ b/examples/tutorial/calculator/Calculator.gf @@ -6,7 +6,7 @@ abstract Calculator = { fun PEmpty : Prog ; - PDecl : Exp -> (Var -> Prog) -> Prog ; + PInit : Exp -> (Var -> Prog) -> Prog ; PAss : Var -> Exp -> Prog -> Prog ; EPlus, EMinus, ETimes, EDiv : Exp -> Exp -> Exp ; @@ -18,8 +18,8 @@ abstract Calculator = { def ex1 = - PDecl (EPlus (EInt 2) (EInt 3)) (\x -> - PDecl (EPlus (EVar x) (EInt 1)) (\y -> + PInit (EPlus (EInt 2) (EInt 3)) (\x -> + PInit (EPlus (EVar x) (EInt 1)) (\y -> PAss x (EPlus (EVar x) (ETimes (EInt 9) (EVar y))) PEmpty)) ; } -- cgit v1.2.3