comparison src/corify.sml @ 111:2d6116de9cca

Closure code generation almost there
author Adam Chlipala <adamc@hcoop.net>
date Sun, 13 Jul 2008 12:06:47 -0400
parents 3739af9e727a
children 541282b81454
comparison
equal deleted inserted replaced
110:3739af9e727a 111:2d6116de9cca
374 ([(L'.DCon (x, n, corifyKind k, corifyCon st c), loc)], st) 374 ([(L'.DCon (x, n, corifyKind k, corifyCon st c), loc)], st)
375 end 375 end
376 | L.DVal (x, n, t, e) => 376 | L.DVal (x, n, t, e) =>
377 let 377 let
378 val (st, n) = St.bindVal st x n 378 val (st, n) = St.bindVal st x n
379 in 379 val s =
380 ([(L'.DVal (x, n, corifyCon st t, corifyExp st e, x), loc)], st) 380 if String.isPrefix "wrap_" x then
381 String.extract (x, 5, NONE)
382 else
383 x
384 in
385 ([(L'.DVal (x, n, corifyCon st t, corifyExp st e, s), loc)], st)
381 end 386 end
382 387
383 | L.DSgn _ => ([], st) 388 | L.DSgn _ => ([], st)
384 389
385 | L.DStr (x, n, _, (L.StrFun (_, na, _, _, str), _)) => 390 | L.DStr (x, n, _, (L.StrFun (_, na, _, _, str), _)) =>