Mercurial > urweb
comparison src/jscomp.sml @ 587:4c899701bd28
Reactive if
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Thu, 01 Jan 2009 11:16:57 -0500 |
parents | 1c969230ee7f |
children | 5803b4f041cb |
comparison
equal
deleted
inserted
replaced
586:1c969230ee7f | 587:4c899701bd28 |
---|---|
168 str "?", | 168 str "?", |
169 succ, | 169 succ, |
170 str ":", | 170 str ":", |
171 fail, | 171 fail, |
172 str ")"] | 172 str ")"] |
173 | PCon _ => raise Fail "jsPat: PCon" | 173 | PCon (_, PConFfi {mod = "Basis", con = "True", ...}, NONE) => |
174 strcat [str ("(d" ^ Int.toString depth ^ "?"), | |
175 succ, | |
176 str ":", | |
177 fail, | |
178 str ")"] | |
179 | PCon (_, PConFfi {mod = "Basis", con = "False", ...}, NONE) => | |
180 strcat [str ("(d" ^ Int.toString depth ^ "?"), | |
181 fail, | |
182 str ":", | |
183 succ, | |
184 str ")"] | |
185 | PCon _ => raise Fail "PCon" | |
174 | PRecord xps => | 186 | PRecord xps => |
175 let | 187 let |
176 val (_, succ) = foldl | 188 val (_, succ) = foldl |
177 (fn ((x, p, _), (inner, succ)) => | 189 (fn ((x, p, _), (inner, succ)) => |
178 (inner + E.patBindsN p, | 190 (inner + E.patBindsN p, |