Mercurial > urweb
comparison src/core_print.sml @ 796:6271f0e3c272
Fix a nasty binding bug in CoreUtil
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Thu, 14 May 2009 09:11:58 -0400 |
parents | fa2019a63ea4 |
children | ef6de4075dc1 |
comparison
equal
deleted
inserted
replaced
795:b87e71e45536 | 796:6271f0e3c272 |
---|---|
196 handle E.UnboundNamed _ => string ("CONSTRUCTOR_" ^ Int.toString n) | 196 handle E.UnboundNamed _ => string ("CONSTRUCTOR_" ^ Int.toString n) |
197 | 197 |
198 fun p_patCon env pc = | 198 fun p_patCon env pc = |
199 case pc of | 199 case pc of |
200 PConVar n => p_con_named env n | 200 PConVar n => p_con_named env n |
201 | PConFfi {mod = m, con, arg, ...} => | 201 | PConFfi {mod = m, con, arg, params, ...} => |
202 if !debug then | 202 if !debug then |
203 box [string "FFIC[", | 203 box [string "FFIC[", |
204 case arg of | 204 case arg of |
205 NONE => box [] | 205 NONE => box [] |
206 | SOME t => p_con env t, | 206 | SOME t => |
207 let | |
208 val k = (KType, ErrorMsg.dummySpan) | |
209 val env' = foldl (fn (x, env) => E.pushCRel env x k) env params | |
210 in | |
211 p_con env' t | |
212 end, | |
207 string "](", | 213 string "](", |
208 string m, | 214 string m, |
209 string ".", | 215 string ".", |
210 string con, | 216 string con, |
211 string ")"] | 217 string ")"] |