a guest Oct 23rd, 2019 101 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
- module FRIST-SYNTAX
- imports BOOL
- syntax Expr ::= Expr "+" Expr [left, strict]
- | "(" Expr ")" [bracket]
- | Ident
- syntax Ident ::= "x" | "y" | "z"
- module FRIST
- imports FRIST-SYNTAX
- rule X + Y => Y + X [anywhere]
- rule X + (Y + Z) => (X + Y) + Z [anywhere]
- rule (X + Y) + Z => X + (Y + Z) [anywhere]
- # kompile frist.k
- [WARNING] Running as root is not recommended
- File "realdef.ml", line 629, characters 289-296:
- Error: This variant expression is expected to have type bool
- The constructor KApply1 does not belong to type bool
- [Error] Critical: ocamlopt returned nonzero exit code: 2
- Examine output to see errors.
RAW Paste Data