comparison src/monoize.sml @ 1571:f403e129c276

Primitive int/float functions: ceil, float, round, trunc
author Adam Chlipala <adam@chlipala.net>
date Sat, 08 Oct 2011 17:23:58 -0400
parents 5691ec310618
children 5530a8075b62
comparison
equal deleted inserted replaced
1570:c7d0328ba777 1571:f403e129c276
1353 val (ch, fm) = monoExp (env, st, fm) ch 1353 val (ch, fm) = monoExp (env, st, fm) ch
1354 in 1354 in
1355 ((L'.EAbs ("_", un, un, (L'.ERecv (liftExpInExp 0 ch, t1), loc)), loc), fm) 1355 ((L'.EAbs ("_", un, un, (L'.ERecv (liftExpInExp 0 ch, t1), loc)), loc), fm)
1356 end 1356 end
1357 | L.EFfiApp ("Basis", "recv", _) => poly () 1357 | L.EFfiApp ("Basis", "recv", _) => poly ()
1358
1359 | L.EFfiApp ("Basis", "float", [e]) =>
1360 let
1361 val (e, fm) = monoExp (env, st, fm) e
1362 in
1363 ((L'.EFfiApp ("Basis", "floatFromInt", [e]), loc), fm)
1364 end
1358 1365
1359 | L.EFfiApp ("Basis", "sleep", [n]) => 1366 | L.EFfiApp ("Basis", "sleep", [n]) =>
1360 let 1367 let
1361 val (n, fm) = monoExp (env, st, fm) n 1368 val (n, fm) = monoExp (env, st, fm) n
1362 in 1369 in