repositories
/
clean-tests.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'master' of git.martlubbers.net:clean-tests
[clean-tests.git]
/
expr
/
exist
/
while.dcl
diff --git
a/expr/exist/while.dcl
b/expr/exist/while.dcl
index
7431e3f
..
a2535f3
100644
(file)
--- a/
expr/exist/while.dcl
+++ b/
expr/exist/while.dcl
@@
-9,20
+9,20
@@
definition module while
| (:.) infixr 0 WhileExpr WhileExpr
| While WhileBool Do WhileExpr
| Skip
| (:.) infixr 0 WhileExpr WhileExpr
| While WhileBool Do WhileExpr
| Skip
- | E.e: WExpr e & eval e
+ | E.e: WExpr e & eval e
& print e
:: WhileBool
= Bool Bool
| (==.) infix 4 WhileInt WhileInt
| (&.) infix 3 WhileBool WhileBool
| Not WhileBool
:: WhileBool
= Bool Bool
| (==.) infix 4 WhileInt WhileInt
| (&.) infix 3 WhileBool WhileBool
| Not WhileBool
- | E.e: WBool e & evalb e
+ | E.e: WBool e & evalb e
& print e
:: WhileInt
= Int Int
| Var String
| (+.) infixl 6 WhileInt WhileInt
:: WhileInt
= Int Int
| Var String
| (+.) infixl 6 WhileInt WhileInt
- | E.e: WInt e & evali e
+ | E.e: WInt e & evali e
& print e
class gamma g
where
class gamma g
where
@@
-40,3
+40,9
@@
class evalb m :: m -> (g -> Bool) | gamma g
instance eval WhileExpr
instance evali WhileInt
instance evalb WhileBool
instance eval WhileExpr
instance evali WhileInt
instance evalb WhileBool
+
+class print m :: m -> String
+
+instance print WhileExpr
+instance print WhileInt
+instance print WhileBool