summaryrefslogtreecommitdiff
path: root/src/cjr.sml
diff options
context:
space:
mode:
Diffstat (limited to 'src/cjr.sml')
-rw-r--r--src/cjr.sml16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/cjr.sml b/src/cjr.sml
index 59f5cb2f..eb035e40 100644
--- a/src/cjr.sml
+++ b/src/cjr.sml
@@ -38,10 +38,24 @@ datatype typ' =
withtype typ = typ' located
+datatype patCon =
+ PConVar of int
+ | PConFfi of string * string
+
+datatype pat' =
+ PWild
+ | PVar of string
+ | PPrim of Prim.t
+ | PCon of patCon * pat option
+ | PRecord of (string * pat) list
+
+withtype pat = pat' located
+
datatype exp' =
EPrim of Prim.t
| ERel of int
| ENamed of int
+ | ECon of int * exp option
| EFfi of string * string
| EFfiApp of string * string * exp list
| EApp of exp * exp
@@ -49,6 +63,8 @@ datatype exp' =
| ERecord of int * (string * exp) list
| EField of exp * string
+ | ECase of exp * (pat * exp) list * typ
+
| EWrite of exp
| ESeq of exp * exp