summaryrefslogtreecommitdiff
path: root/src/core_util.sml
diff options
context:
space:
mode:
Diffstat (limited to 'src/core_util.sml')
-rw-r--r--src/core_util.sml10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/core_util.sml b/src/core_util.sml
index 9cde8ab9..1964ce9d 100644
--- a/src/core_util.sml
+++ b/src/core_util.sml
@@ -282,6 +282,16 @@ fun mapfoldB {kind = fk, con = fc, exp = fe, bind} =
S.map2 (mfc ctx rest,
fn rest' =>
(EField (e', c', {field = field', rest = rest'}), loc)))))
+ | ECut (e, c, {field, rest}) =>
+ S.bind2 (mfe ctx e,
+ fn e' =>
+ S.bind2 (mfc ctx c,
+ fn c' =>
+ S.bind2 (mfc ctx field,
+ fn field' =>
+ S.map2 (mfc ctx rest,
+ fn rest' =>
+ (ECut (e', c', {field = field', rest = rest'}), loc)))))
| EFold k =>
S.map2 (mfk k,
fn k' =>