comparison src/elab.sml @ 156:34ccd7d2bea8

Start of datatype support
author Adam Chlipala <adamc@hcoop.net>
date Thu, 24 Jul 2008 15:02:03 -0400
parents 7420fa18d657
children 06a98129b23f
comparison
equal deleted inserted replaced
155:4334bb734187 156:34ccd7d2bea8
91 withtype exp = exp' located 91 withtype exp = exp' located
92 92
93 datatype sgn_item' = 93 datatype sgn_item' =
94 SgiConAbs of string * int * kind 94 SgiConAbs of string * int * kind
95 | SgiCon of string * int * kind * con 95 | SgiCon of string * int * kind * con
96 | SgiDatatype of string * int * (string * int * con option) list
97 | SgiDatatypeImp of string * int * int * string list * string
96 | SgiVal of string * int * con 98 | SgiVal of string * int * con
97 | SgiStr of string * int * sgn 99 | SgiStr of string * int * sgn
98 | SgiSgn of string * int * sgn 100 | SgiSgn of string * int * sgn
99 | SgiConstraint of con * con 101 | SgiConstraint of con * con
100 102
109 withtype sgn_item = sgn_item' located 111 withtype sgn_item = sgn_item' located
110 and sgn = sgn' located 112 and sgn = sgn' located
111 113
112 datatype decl' = 114 datatype decl' =
113 DCon of string * int * kind * con 115 DCon of string * int * kind * con
116 | DDatatype of string * int * (string * int * con option) list
117 | DDatatypeImp of string * int * int * string list * string
114 | DVal of string * int * con * exp 118 | DVal of string * int * con * exp
115 | DValRec of (string * int * con * exp) list 119 | DValRec of (string * int * con * exp) list
116 | DSgn of string * int * sgn 120 | DSgn of string * int * sgn
117 | DStr of string * int * sgn * str 121 | DStr of string * int * sgn * str
118 | DFfiStr of string * int * sgn 122 | DFfiStr of string * int * sgn