diff src/source.sml @ 170:a158f8c5aa55

Parsing basic patterns
author Adam Chlipala <adamc@hcoop.net>
date Tue, 29 Jul 2008 16:38:15 -0400
parents 34ccd7d2bea8
children 8221b95cc24c
line wrap: on
line diff
--- a/src/source.sml	Tue Jul 29 16:02:02 2008 -0400
+++ b/src/source.sml	Tue Jul 29 16:38:15 2008 -0400
@@ -89,6 +89,13 @@
 withtype sgn_item = sgn_item' located
 and sgn = sgn' located
 
+datatype pat' =
+         PWild
+       | PVar of string
+       | PCon of string list * string * pat option
+
+withtype pat = pat' located
+
 datatype exp' =
          EAnnot of exp * con
 
@@ -105,6 +112,8 @@
        | ECut of exp * con
        | EFold
 
+       | ECase of exp * (pat * exp) list
+
 withtype exp = exp' located
 
 datatype decl' =