diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/mono_reduce.sml | 2 | ||||
-rw-r--r-- | src/monoize.sml | 6 |
2 files changed, 5 insertions, 3 deletions
diff --git a/src/mono_reduce.sml b/src/mono_reduce.sml index 2f60b26e..dafc6ded 100644 --- a/src/mono_reduce.sml +++ b/src/mono_reduce.sml @@ -61,7 +61,6 @@ fun impure (e, _) = | EFfiApp ("Basis", "new_channel", _) => true | EFfiApp ("Basis", "subscribe", _) => true | EFfiApp ("Basis", "send", _) => true - | EFfiApp ("Basis", "recv", _) => true | EFfiApp _ => false | EApp ((EFfi _, _), _) => false | EApp _ => true @@ -283,7 +282,6 @@ fun reduce file = | EFfiApp ("Basis", "new_channel", es) => ffi es | EFfiApp ("Basis", "subscribe", es) => ffi es | EFfiApp ("Basis", "send", es) => ffi es - | EFfiApp ("Basis", "recv", es) => ffi es | EFfiApp (_, _, es) => List.concat (map (summarize d) es) | EApp ((EFfi _, _), e) => summarize d e | EApp _ => diff --git a/src/monoize.sml b/src/monoize.sml index d974e373..620e43a5 100644 --- a/src/monoize.sml +++ b/src/monoize.sml @@ -984,6 +984,7 @@ fun monoExp (env, st, fm) (all as (e, loc)) = loc)), loc)), loc)), loc)), loc), fm) end + | L.EApp ((L.EApp ((L.ECApp ((L.ECApp ((L.ECApp ((L.EFfi ("Basis", "bind"), _), _), _), _), _), t2), _), (L.EFfi ("Basis", "transaction_monad"), _)), _), (L.EApp ((L.ECApp ((L.EFfi ("Basis", "recv"), _), t1), _), @@ -1002,6 +1003,8 @@ fun monoExp (env, st, fm) (all as (e, loc)) = t1), loc)), loc)), loc), fm) end + | L.EFfiApp ("Basis", "recv", _) => poly () + | L.EApp ((L.EApp ((L.ECApp ((L.ECApp ((L.ECApp ((L.EFfi ("Basis", "bind"), _), _), _), _), _), t2), _), (L.EFfi ("Basis", "transaction_monad"), _)), _), (L.EAbs (_, _, _, @@ -1014,11 +1017,12 @@ fun monoExp (env, st, fm) (all as (e, loc)) = in ((L'.EAbs ("m2", (L'.TFun (un, mt2), loc), (L'.TFun (un, un), loc), (L'.EAbs ("_", un, un, - (L'.ESleep (n, (L'.EApp ((L'.ERel 1, loc), + (L'.ESleep (liftExpInExp 0 n, (L'.EApp ((L'.ERel 1, loc), (L'.ERecord [], loc)), loc)), loc)), loc)), loc), fm) end + | L.EFfiApp ("Basis", "sleep", _) => poly () | L.ECApp ((L.EFfi ("Basis", "source"), _), t) => let |