chore: update stage0
diff --git a/stage0/stdlib/Lean/Elab/Do.c b/stage0/stdlib/Lean/Elab/Do.c
index 401dd1b..4ce71a0 100644
--- a/stage0/stdlib/Lean/Elab/Do.c
+++ b/stage0/stdlib/Lean/Elab/Do.c
@@ -90,7 +90,6 @@
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___lambda__2___closed__2;
 static lean_object* l_Lean_Elab_Term_Do_mkAuxDeclFor___rarg___lambda__5___closed__6;
 static lean_object* l_Lean_Elab_Term_Do_getDoHaveVars___closed__3;
-static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__15;
 LEAN_EXPORT lean_object* l_panic___at_Lean_Elab_Term_Do_ToTerm_returnToTerm___spec__1(lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doLetArrowToCode___lambda__4(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doForToCode___closed__7;
@@ -132,7 +131,6 @@
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_hasExitPointPred_loop(lean_object*, lean_object*);
 static lean_object* l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__5___lambda__2___closed__14;
 LEAN_EXPORT lean_object* l_Array_mapMUnsafe_map___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__3(size_t, size_t, lean_object*);
-static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__8;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_actionTerminalToTerm___closed__6;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_hasBreakContinueReturn(lean_object*);
 static lean_object* l_Array_foldrMUnsafe_fold___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkTuple___spec__1___closed__5;
@@ -152,10 +150,12 @@
 static lean_object* l___regBuiltin_Lean_Elab_Term_expandTermFor___closed__1;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doLetElseToCode___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
+static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__5;
 LEAN_EXPORT lean_object* l_Lean_throwMaxRecDepthAt___at_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode___spec__7___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeq___boxed(lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__3;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_reassignToTerm___closed__2;
+static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__2;
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkPureUnit___closed__8;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_getDoLetVars___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_liftMacroM___at_Lean_Elab_Term_Do_mkJmp___spec__1___lambda__3___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
@@ -191,8 +191,8 @@
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__7;
 lean_object* l_Lean_Syntax_getId(lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doForToCode___lambda__3___closed__17;
+static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__8;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_actionTerminalToTerm___closed__14;
-LEAN_EXPORT lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501_(lean_object*);
 uint8_t l_Lean_RBNode_isRed___rarg(lean_object*);
 lean_object* l_Lean_Expr_sort___override(lean_object*);
 LEAN_EXPORT uint8_t l_Lean_Elab_Term_Do_hasExitPoint___lambda__1(lean_object*);
@@ -227,7 +227,6 @@
 LEAN_EXPORT lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_toDoElem___boxed(lean_object*, lean_object*, lean_object*, lean_object*);
 lean_object* l_Lean_Syntax_getArgs(lean_object*);
 lean_object* l_Lean_Elab_Term_getPatternsVars(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
-static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__4;
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkPureUnit___closed__2;
 LEAN_EXPORT lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_ToCodeBlock_expandLiftMethodAux___lambda__3___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_throwError___at___private_Lean_Elab_Do_0__Lean_Elab_Term_extractBind___spec__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
@@ -251,11 +250,13 @@
 static lean_object* l_Lean_Elab_Term_Do_mkSimpleJmp___closed__3;
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doReturnToCode___closed__2;
 static lean_object* l___regBuiltin_Lean_Elab_Term_Do_elabDo___closed__4;
+static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__16;
 lean_object* lean_array_fget(lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_addTrace___at_Lean_Elab_Term_Do_ToCodeBlock_mkForInBody___spec__3___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Array_mapMUnsafe_map___at_Lean_Elab_Term_Do_mkDoSeq___spec__1(size_t, size_t, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_pullExitPointsAux___lambda__1___closed__9;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_actionTerminalToTerm___closed__20;
+static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__6;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_instInhabitedAltExpr___rarg(lean_object*);
 LEAN_EXPORT lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkPureUnit(lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Array_mapMUnsafe_map___at_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode___spec__2(size_t, size_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
@@ -264,6 +265,7 @@
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Array_foldrMUnsafe_fold___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkTuple___spec__1___closed__2;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_breakToTerm___closed__20;
+static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__4;
 LEAN_EXPORT lean_object* l_Array_anyMUnsafe_any___at_Lean_Elab_Term_Do_extendUpdatedVarsAux_update___spec__5___boxed(lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_Do_CodeBlocl_toMessageData_loop___spec__2___closed__5;
 static lean_object* l_Array_mapMUnsafe_map___at_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode___spec__2___closed__8;
@@ -296,7 +298,6 @@
 LEAN_EXPORT lean_object* l_Lean_throwError___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_ToCodeBlock_expandLiftMethodAux___spec__9(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToCodeBlock_checkNotShadowingMutable___spec__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_matchNestedTermResult___closed__1;
-static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__5;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doForToCode___lambda__3(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_Context_mutableVars___default;
 static lean_object* l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToCodeBlock_checkReassignable___spec__2___closed__1;
@@ -338,11 +339,13 @@
 LEAN_EXPORT lean_object* l_List_forM___at_Lean_Elab_Term_Do_ToCodeBlock_mkForInBody___spec__4(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_mkAuxDeclFor___rarg___lambda__5___closed__2;
 static lean_object* l_Lean_Elab_Term_Do_CodeBlocl_toMessageData_loop___closed__16;
+static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__12;
 lean_object* l_Lean_Syntax_node5(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_seqToTerm___closed__10;
 uint8_t l_Lean_Syntax_isOfKind(lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__9;
 lean_object* l_Lean_Name_mkStr5(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
+static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__9;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_continueToTerm___closed__4;
 static lean_object* l_Lean_Elab_Term_Do_mkAuxDeclFor___rarg___lambda__5___closed__5;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_returnToTerm___closed__36;
@@ -440,7 +443,6 @@
 LEAN_EXPORT uint8_t l_Array_anyMUnsafe_any___at___private_Lean_Elab_Do_0__Lean_Elab_Term_hasLiftMethod___spec__1(lean_object*, size_t, size_t);
 static lean_object* l_Array_foldrMUnsafe_fold___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkTuple___spec__1___closed__6;
 static lean_object* l___regBuiltin_Lean_Elab_Term_elabLiftMethod_declRange___closed__1;
-static lean_object* l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__4;
 static lean_object* l_Array_mapMUnsafe_map___at_Lean_Elab_Term_Do_ToTerm_mkJoinPoint___spec__4___closed__1;
 LEAN_EXPORT uint8_t l_Array_anyMUnsafe_any___at_Lean_Elab_Term_Do_extendUpdatedVarsAux_update___spec__2(lean_object*, lean_object*, size_t, size_t);
 LEAN_EXPORT uint8_t l_Array_anyMUnsafe_any___at_Lean_Elab_Term_Do_hasExitPointPred_loop___spec__1(lean_object*, lean_object*, size_t, size_t);
@@ -464,6 +466,7 @@
 lean_object* l_List_appendTR___rarg(lean_object*, lean_object*);
 static lean_object* l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__3;
 static lean_object* l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_AltExpr_vars___spec__1___closed__2;
+static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__18;
 static lean_object* l_Lean_Elab_Term_Do_elabDo___closed__1;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_returnToTerm___closed__26;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_actionTerminalToTerm___closed__7;
@@ -490,7 +493,6 @@
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_getDoHaveVars(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___closed__4;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_matchNestedTermResult___closed__16;
-static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__16;
 LEAN_EXPORT uint8_t l_Array_anyMUnsafe_any___at_Lean_Elab_Term_Do_extendUpdatedVarsAux_update___spec__5(lean_object*, lean_object*, size_t, size_t);
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_continueToTerm___closed__36;
 LEAN_EXPORT lean_object* l_Lean_throwMaxRecDepthAt___at_Lean_Elab_Term_Do_concat___spec__4___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
@@ -534,6 +536,7 @@
 uint8_t lean_expr_eqv(lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_continueToTerm___closed__40;
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__7;
+static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__1;
 LEAN_EXPORT lean_object* l_Array_foldrMUnsafe_fold___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkTuple___spec__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 lean_object* l_Lean_ResolveName_resolveNamespace(lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_breakToTerm___closed__14;
@@ -545,13 +548,13 @@
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_returnToTerm___closed__24;
 static lean_object* l_Lean_Elab_Term_Do_CodeBlocl_toMessageData_loop___closed__6;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_mkAuxDeclFor___rarg___lambda__2(lean_object*, lean_object*, lean_object*, lean_object*);
-static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__18;
 static lean_object* l_Lean_Elab_Term_Do_mkAuxDeclFor___rarg___lambda__8___closed__4;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_expandTermReturn___boxed(lean_object*, lean_object*, lean_object*);
 lean_object* l_Lean_SourceInfo_fromRef(lean_object*, uint8_t);
 LEAN_EXPORT lean_object* l_Array_mapMUnsafe_map___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_ToCodeBlock_expandLiftMethodAux___spec__4(lean_object*, uint8_t, size_t, size_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 lean_object* l_Lean_RBNode_setBlack___rarg(lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_mkAuxDeclFor___rarg(lean_object*, lean_object*, lean_object*, lean_object*);
+static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__9;
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkUnit___closed__7;
 static lean_object* l___regBuiltin_Lean_Elab_Term_Do_elabDo_declRange___closed__2;
 LEAN_EXPORT lean_object* l_Lean_Elab_liftMacroM___at_Lean_Elab_Term_Do_mkJmp___spec__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
@@ -559,7 +562,6 @@
 lean_object* l_Lean_MessageData_ofSyntax(lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_pullExitPointsAux___lambda__3___boxed(lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___closed__6;
-static lean_object* l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__20;
 lean_object* l_Lean_Syntax_node6(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_throwErrorAt___at_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___spec__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_throwError___at_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode___spec__6___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
@@ -574,7 +576,6 @@
 lean_object* l_Lean_mkHole(lean_object*, uint8_t);
 LEAN_EXPORT lean_object* l_Lean_Elab_throwUnsupportedSyntax___at_Lean_Elab_Term_Do_concat___spec__5___rarg(lean_object*);
 LEAN_EXPORT lean_object* l_Array_anyMUnsafe_any___at_Lean_Elab_Term_Do_hasExitPointPred_loop___spec__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*);
-static lean_object* l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__21;
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__1;
 LEAN_EXPORT lean_object* l_Lean_Elab_liftMacroM___at_Lean_Elab_Term_Do_mkJmp___spec__1___lambda__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_mkJoinPoint___closed__1;
@@ -631,6 +632,7 @@
 uint8_t l_Lean_Expr_isMVar(lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_mkSeq(lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_hasLiftMethod___boxed(lean_object*);
+static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__11;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_instInhabitedAlt___rarg(lean_object*);
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__4;
 LEAN_EXPORT lean_object* l_Lean_Elab_liftMacroM___at_Lean_Elab_Term_Do_mkJmp___spec__1___lambda__2___boxed(lean_object*, lean_object*, lean_object*, lean_object*);
@@ -643,6 +645,7 @@
 static lean_object* l___regBuiltin_Lean_Elab_Term_expandTermFor___closed__4;
 LEAN_EXPORT lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_Do_CodeBlocl_toMessageData_loop___spec__6___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_getPatternVarsEx(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
+static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__1;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_reassignToTerm___closed__3;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_attachJPs(lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_mkAuxDeclFor___at_Lean_Elab_Term_Do_pullExitPointsAux___spec__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
@@ -675,7 +678,6 @@
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_liftMethodDelimiter___closed__10;
 LEAN_EXPORT lean_object* l_Lean_addTrace___at_Lean_Elab_Term_Do_ToCodeBlock_mkForInBody___spec__3(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_mkUnknownMonadResult___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
-static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__1;
 static lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode___spec__10___closed__5;
 lean_object* l_Lean_Meta_mkAppM(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_returnToTerm___closed__41;
@@ -684,7 +686,6 @@
 static lean_object* l_panic___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___spec__1___closed__1;
 lean_object* l_List_forM___at___private_Lean_Elab_Term_0__Lean_Elab_Term_elabTermAux___spec__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_CodeBlocl_toMessageData_loop___closed__10;
-static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__10;
 LEAN_EXPORT lean_object* l_Lean_Elab_liftMacroM___at_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___spec__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__5___lambda__2___closed__7;
 uint8_t l_List_isEmpty___rarg(lean_object*);
@@ -725,10 +726,10 @@
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_liftMethodDelimiter___closed__4;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_actionTerminalToTerm___closed__11;
 lean_object* l_instInhabited___rarg(lean_object*, lean_object*);
+static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__3;
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doForToCode___closed__1;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_ensureInsideFor(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_mkSimpleJmp___closed__6;
-static lean_object* l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__19;
 static lean_object* l___regBuiltin_Lean_Elab_Term_expandTermUnless_declRange___closed__3;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_mkReassignCore___lambda__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_getDoLetRecVars(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
@@ -751,6 +752,7 @@
 static lean_object* l_Array_mapMUnsafe_map___at_Lean_Elab_Term_Do_ToTerm_mkJoinPoint___spec__1___closed__3;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_returnToTerm___closed__19;
 static lean_object* l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__5___lambda__2___closed__9;
+static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__3;
 LEAN_EXPORT lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_extractBind_extract_x3f(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_breakToTerm___closed__2;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_checkReassignable___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
@@ -814,6 +816,7 @@
 LEAN_EXPORT lean_object* l_Array_anyMUnsafe_any___at_Lean_Elab_Term_Do_extendUpdatedVarsAux_update___spec__2___boxed(lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_List_mapTR_loop___at_Lean_Elab_Term_Do_CodeBlocl_toMessageData_loop___spec__7(lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doForToCode___closed__15;
+static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__8;
 extern lean_object* l_Lean_Elab_macroAttribute;
 static lean_object* l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__5___lambda__2___closed__4;
 LEAN_EXPORT lean_object* l_Lean_throwMaxRecDepthAt___at_Lean_Elab_Term_Do_ToCodeBlock_doMatchToCode___spec__4(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
@@ -840,12 +843,12 @@
 uint8_t l_Lean_Syntax_isEscapedAntiquot(lean_object*);
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__1;
 LEAN_EXPORT lean_object* l_Array_mapMUnsafe_map___at_Lean_Elab_Term_Do_extendUpdatedVarsAux_update___spec__3___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
-static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__11;
 LEAN_EXPORT lean_object* l_Lean_throwErrorAt___at_Lean_Elab_Term_Do_ToCodeBlock_doMatchToCode___spec__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 lean_object* l___private_Init_Util_0__mkPanicMessageWithDecl(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 uint8_t l_Lean_Syntax_matchesNull(lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_liftMacroM___at_Lean_Elab_Term_Do_concat___spec__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToTerm_Kind_toCtorIdx(uint8_t);
+static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__7;
 static lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode___spec__10___closed__2;
 static lean_object* l_Lean_Elab_Term_Do_mkSimpleJmp___closed__5;
 static lean_object* l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__5___lambda__2___closed__8;
@@ -854,14 +857,12 @@
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doReassignArrowToCode(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 lean_object* l___private_Lean_Meta_Basic_0__Lean_Meta_mkFreshExprMVarImpl(lean_object*, uint8_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_hasExitPoint___lambda__1___boxed(lean_object*);
-static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__2;
 static lean_object* l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToCodeBlock_checkNotShadowingMutable___spec__1___closed__4;
 lean_object* l_Lean_Meta_saveState___rarg(lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___closed__5;
 uint8_t l_Lean_Syntax_isIdent(lean_object*);
 lean_object* l_Lean_Elab_liftMacroM___at___private_Lean_Elab_Term_0__Lean_Elab_Term_elabTermAux___spec__9(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_panic___at_Lean_Elab_Term_Do_ToTerm_matchNestedTermResult___spec__1___closed__2;
-static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__6;
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkUnit___closed__16;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_continueToTerm___closed__34;
 static lean_object* l___regBuiltin_Lean_Elab_Term_expandTermUnless_declRange___closed__7;
@@ -875,6 +876,7 @@
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_returnToTerm___closed__33;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_getTryCatchUpdatedVars___boxed(lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_mkAuxDeclFor___rarg___lambda__8___boxed(lean_object*, lean_object*, lean_object*, lean_object*);
+static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__6;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToTerm_matchNestedTermResult(lean_object*, lean_object*, uint8_t, uint8_t, uint8_t, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_seqToTerm___closed__7;
 LEAN_EXPORT lean_object* l_Array_mapMUnsafe_map___at_Lean_Elab_Term_Do_convertTerminalActionIntoJmp_loop___spec__2___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
@@ -906,6 +908,7 @@
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__6;
 static lean_object* l_Lean_Elab_Term_Do_CodeBlocl_toMessageData_loop___closed__34;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToTerm_mkNestedKind___boxed(lean_object*, lean_object*, lean_object*);
+static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__11;
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doReassignArrowToCode___lambda__1___closed__3;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToTerm_mkNestedKind(uint8_t, uint8_t, uint8_t);
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_breakToTerm___closed__22;
@@ -922,9 +925,9 @@
 extern lean_object* l_Lean_inheritedTraceOptions;
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_ToCodeBlock_expandLiftMethodAux___closed__6;
 static lean_object* l___regBuiltin_Lean_Elab_Term_Do_elabDo_declRange___closed__1;
+static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__5;
 LEAN_EXPORT lean_object* l_Array_sequenceMap___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__1___boxed(lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doMatchToCode(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
-static lean_object* l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__5;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_continueToTerm___closed__22;
 LEAN_EXPORT lean_object* l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__5(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, size_t, size_t, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doForToCode___lambda__3___closed__21;
@@ -941,6 +944,7 @@
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doMatchExprToCode(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_throwMaxRecDepthAt___at_Lean_Elab_Term_Do_mkJmp___spec__7___closed__1;
 LEAN_EXPORT lean_object* l_Lean_Elab_throwUnsupportedSyntax___at_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___spec__10___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
+static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__15;
 LEAN_EXPORT lean_object* l_Array_mapMUnsafe_map___at_Lean_Elab_Term_Do_pullExitPointsAux___spec__2(lean_object*, size_t, size_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkUnit___closed__1;
 static lean_object* l_Lean_isTracingEnabledFor___at_Lean_Elab_Term_Do_mkJmp___spec__2___closed__1;
@@ -953,6 +957,7 @@
 lean_object* l_Array_extract___rarg(lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_returnToTerm___closed__35;
 lean_object* l_Lean_Syntax_node4(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
+static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__12;
 LEAN_EXPORT lean_object* l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__6(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, size_t, size_t, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode___spec__10___closed__14;
 LEAN_EXPORT lean_object* l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToCodeBlock_checkReassignable___spec__2___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
@@ -961,6 +966,7 @@
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_getLetIdDeclVars(lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_annotate___rarg___lambda__1___closed__1;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_mkAuxDeclFor(lean_object*);
+LEAN_EXPORT lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f(lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_homogenize(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l___regBuiltin_Lean_Elab_Term_expandTermTry___closed__2;
 LEAN_EXPORT lean_object* l___regBuiltin_Lean_Elab_Term_expandTermUnless_declRange(lean_object*);
@@ -1051,7 +1057,6 @@
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_hasBreakContinue(lean_object*);
 lean_object* l_Lean_throwError___at_Lean_Elab_Term_synthesizeInstMVarCore___spec__3(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_expandTermReturn(lean_object*, lean_object*, lean_object*);
-static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__3;
 lean_object* l_Lean_Syntax_SepArray_ofElems(lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_returnToTerm___closed__28;
 LEAN_EXPORT uint8_t l_Lean_Elab_Term_Do_ToTerm_Kind_isRegular(uint8_t);
@@ -1086,6 +1091,7 @@
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___lambda__2___closed__7;
 LEAN_EXPORT uint8_t l_Lean_RBNode_any___at_Lean_Elab_Term_Do_extendUpdatedVars___spec__1(lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_throwMaxRecDepthAt___at_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___spec__4(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
+static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_object* l_Lean_indentExpr(lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_mkMatch(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__7;
@@ -1108,6 +1114,7 @@
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_pullExitPointsAux___lambda__1(lean_object*, lean_object*, lean_object*);
 lean_object* l_Lean_Syntax_node1(lean_object*, lean_object*, lean_object*);
 lean_object* l_Lean_Meta_unfoldDefinition_x3f(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
+static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__4;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_breakToTerm___closed__8;
 static lean_object* l_Array_foldrMUnsafe_fold___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkTuple___spec__1___closed__9;
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doForToCode___lambda__3___closed__19;
@@ -1129,6 +1136,7 @@
 lean_object* l_Lean_addMessageContextFull___at_Lean_Meta_instAddMessageContextMetaM___spec__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT uint8_t l_Array_anyMUnsafe_any___at_Lean_Elab_Term_Do_extendUpdatedVarsAux_update___spec__7(lean_object*, lean_object*, size_t, size_t);
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_returnToTerm___closed__40;
+static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__13;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_returnToTerm___closed__5;
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_liftMethodDelimiter___closed__1;
 static lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode___spec__10___closed__12;
@@ -1140,7 +1148,6 @@
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_actionTerminalToTerm___closed__5;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToTerm_run(lean_object*, lean_object*, lean_object*, lean_object*, uint8_t, lean_object*, lean_object*);
 LEAN_EXPORT uint8_t l_Lean_Elab_Term_Do_hasBreakContinue___lambda__1(lean_object*);
-static lean_object* l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__6;
 static lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_Do_CodeBlocl_toMessageData_loop___spec__2___closed__1;
 LEAN_EXPORT lean_object* l_Lean_RBNode_ins___at_Lean_Elab_Term_Do_insertVars___spec__2(lean_object*, lean_object*, lean_object*);
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_liftMethodForbiddenBinder___closed__7;
@@ -1157,6 +1164,7 @@
 LEAN_EXPORT lean_object* l_Array_mapMUnsafe_map___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_ToCodeBlock_expandLiftMethodAux___spec__3___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_declToTerm___closed__6;
 uint8_t l_Lean_RBNode_isBlack___rarg(lean_object*);
+static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__14;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_attachJP(lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doForToCode___lambda__3___closed__14;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_eraseVars(lean_object*, lean_object*);
@@ -1166,23 +1174,20 @@
 LEAN_EXPORT lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode___spec__10(lean_object*, lean_object*, lean_object*, uint8_t, uint8_t, uint8_t, lean_object*, lean_object*, lean_object*, size_t, size_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_Do_CodeBlocl_toMessageData_loop___spec__5(lean_object*, lean_object*, lean_object*, size_t, size_t, lean_object*);
 LEAN_EXPORT lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_Do_mkMatchExpr___spec__2___boxed(lean_object*, lean_object*, lean_object*, lean_object*);
-static lean_object* l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__17;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_continueToTerm___closed__39;
 static lean_object* l_Lean_Elab_Term_Do_CodeBlocl_toMessageData_loop___closed__1;
-static lean_object* l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__18;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_actionTerminalToTerm___closed__1;
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doReassignArrowToCode___closed__2;
 LEAN_EXPORT lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_Do_insertVars___spec__3(lean_object*, size_t, size_t, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_throwMaxRecDepthAt___at_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___spec__9(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
-static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__13;
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__6;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_expandTermFor(lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_getDoHaveVars___closed__6;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_mkAuxDeclFor___rarg___lambda__6(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
-static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__7;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode___lambda__5(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, size_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__14;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_actionTerminalToTerm___closed__17;
+static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__2;
 static lean_object* l_Lean_Elab_Term_Do_mkSimpleJmp___closed__2;
 lean_object* l_Lean_mkArrow(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_liftMethodForbiddenBinder___closed__10;
@@ -1214,7 +1219,6 @@
 LEAN_EXPORT lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_extractBind___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_instInhabitedAltExpr(lean_object*);
 LEAN_EXPORT lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_letDeclArgHasBinders___boxed(lean_object*);
-static lean_object* l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__7;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_matchNestedTermResult___closed__20;
 static lean_object* l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__5___lambda__2___closed__16;
 LEAN_EXPORT lean_object* l___regBuiltin_Lean_Elab_Term_elabLiftMethod(lean_object*);
@@ -1270,7 +1274,6 @@
 static lean_object* l_Lean_Elab_Term_Do_CodeBlocl_toMessageData_loop___closed__21;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_mkMatchExpr(lean_object*, uint8_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_pullExitPointsAux(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
-static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__12;
 lean_object* l_Lean_Macro_expandMacro_x3f(lean_object*, lean_object*, lean_object*);
 lean_object* l_Lean_Syntax_node8(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_CodeBlocl_toMessageData_loop___closed__30;
@@ -1333,6 +1336,7 @@
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doForToCode___closed__5;
 LEAN_EXPORT lean_object* l_Lean_throwError___at_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode___spec__9___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 lean_object* l_Lean_mkAtomFrom(lean_object*, lean_object*, uint8_t);
+static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__13;
 lean_object* l_Lean_Elab_Term_expandMatchAlt(lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_mkNestedKind___closed__1;
 LEAN_EXPORT lean_object* l_Array_mapMUnsafe_map___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_ToCodeBlock_expandLiftMethodAux___spec__5(lean_object*, size_t, size_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
@@ -1364,6 +1368,7 @@
 static lean_object* l___regBuiltin_Lean_Elab_Term_elabLiftMethod___closed__4;
 LEAN_EXPORT lean_object* l_Lean_throwErrorAt___at_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___spec__7(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_actionTerminalToTerm___closed__25;
+static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__7;
 uint8_t lean_nat_dec_le(lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_hasBreakContinueReturn___closed__1;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_mkAuxDeclFor___at_Lean_Elab_Term_Do_pullExitPointsAux___spec__1___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
@@ -1411,7 +1416,6 @@
 static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__7;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_pullExitPointsAux___lambda__3(lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode___lambda__2___closed__2;
-static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__9;
 LEAN_EXPORT lean_object* l_List_forM___at_Lean_Elab_Term_Do_mkJmp___spec__4___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Array_mapMUnsafe_map___at_Lean_Elab_Term_Do_convertTerminalActionIntoJmp_loop___spec__3___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_annotate___at_Lean_Elab_Term_Do_ToTerm_toTerm___spec__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
@@ -1438,11 +1442,13 @@
 lean_object* l_String_toSubstring_x27(lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_mkAuxDeclFor___rarg___lambda__10(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_AltExpr_vars___rarg(lean_object*);
+static lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__10;
 static lean_object* l_Lean_Elab_Term_Do_ToTerm_continueToTerm___closed__28;
 lean_object* lean_array_uset(lean_object*, size_t, lean_object*);
 lean_object* l_Lean_MessageData_ofName(lean_object*);
 static lean_object* l_Lean_Elab_Term_Do_annotate___rarg___lambda__1___closed__2;
 LEAN_EXPORT lean_object* l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__8(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, size_t, size_t, lean_object*, lean_object*, lean_object*);
+LEAN_EXPORT lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132_(lean_object*);
 static lean_object* l_Lean_Elab_throwUnsupportedSyntax___at_Lean_Elab_Term_Do_mkJmp___spec__8___rarg___closed__1;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_annotate___at_Lean_Elab_Term_Do_ToTerm_toTerm___spec__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 lean_object* l_Lean_Elab_Term_withMacroExpansion___rarg(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
@@ -1487,6 +1493,7 @@
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_convertTerminalActionIntoJmp_loop___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode___spec__10___closed__1;
 static lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doForToCode___lambda__3___closed__18;
+static lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__10;
 LEAN_EXPORT lean_object* l_Array_mapMUnsafe_map___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_ToCodeBlock_expandLiftMethodAux___spec__6(lean_object*, uint8_t, size_t, size_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToTerm_Kind_noConfusion___rarg___lambda__1(lean_object*);
 LEAN_EXPORT lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___lambda__3(lean_object*, lean_object*, lean_object*);
@@ -17890,6 +17897,421 @@
 return x_8;
 }
 }
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__1() {
+_start:
+{
+lean_object* x_1; 
+x_1 = lean_mk_string_from_bytes("doLetExpr", 9);
+return x_1;
+}
+}
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__2() {
+_start:
+{
+lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; 
+x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__1;
+x_2 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__2;
+x_3 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__3;
+x_4 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__1;
+x_5 = l_Lean_Name_mkStr4(x_1, x_2, x_3, x_4);
+return x_5;
+}
+}
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__3() {
+_start:
+{
+lean_object* x_1; 
+x_1 = lean_mk_string_from_bytes("doLetMetaExpr", 13);
+return x_1;
+}
+}
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__4() {
+_start:
+{
+lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; 
+x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__1;
+x_2 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__2;
+x_3 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__3;
+x_4 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__3;
+x_5 = l_Lean_Name_mkStr4(x_1, x_2, x_3, x_4);
+return x_5;
+}
+}
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__5() {
+_start:
+{
+lean_object* x_1; 
+x_1 = lean_mk_string_from_bytes("matchExprPat", 12);
+return x_1;
+}
+}
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__6() {
+_start:
+{
+lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; 
+x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__1;
+x_2 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__2;
+x_3 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__3;
+x_4 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__5;
+x_5 = l_Lean_Name_mkStr4(x_1, x_2, x_3, x_4);
+return x_5;
+}
+}
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__7() {
+_start:
+{
+lean_object* x_1; 
+x_1 = lean_mk_string_from_bytes("doMatchExpr", 11);
+return x_1;
+}
+}
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__8() {
+_start:
+{
+lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; 
+x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__1;
+x_2 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__2;
+x_3 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__3;
+x_4 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__7;
+x_5 = l_Lean_Name_mkStr4(x_1, x_2, x_3, x_4);
+return x_5;
+}
+}
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__9() {
+_start:
+{
+lean_object* x_1; 
+x_1 = lean_mk_string_from_bytes("match_expr", 10);
+return x_1;
+}
+}
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__10() {
+_start:
+{
+lean_object* x_1; 
+x_1 = lean_mk_string_from_bytes("matchExprAlts", 13);
+return x_1;
+}
+}
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__11() {
+_start:
+{
+lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; 
+x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__1;
+x_2 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__2;
+x_3 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__3;
+x_4 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__10;
+x_5 = l_Lean_Name_mkStr4(x_1, x_2, x_3, x_4);
+return x_5;
+}
+}
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__12() {
+_start:
+{
+lean_object* x_1; 
+x_1 = lean_mk_string_from_bytes("matchExprAlt", 12);
+return x_1;
+}
+}
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__13() {
+_start:
+{
+lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; 
+x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__1;
+x_2 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__2;
+x_3 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__3;
+x_4 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__12;
+x_5 = l_Lean_Name_mkStr4(x_1, x_2, x_3, x_4);
+return x_5;
+}
+}
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__14() {
+_start:
+{
+lean_object* x_1; 
+x_1 = lean_mk_string_from_bytes("matchExprElseAlt", 16);
+return x_1;
+}
+}
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__15() {
+_start:
+{
+lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; 
+x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__1;
+x_2 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__2;
+x_3 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__3;
+x_4 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__14;
+x_5 = l_Lean_Name_mkStr4(x_1, x_2, x_3, x_4);
+return x_5;
+}
+}
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__16() {
+_start:
+{
+lean_object* x_1; 
+x_1 = lean_mk_string_from_bytes("meta", 4);
+return x_1;
+}
+}
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17() {
+_start:
+{
+lean_object* x_1; 
+x_1 = lean_mk_string_from_bytes(":=", 2);
+return x_1;
+}
+}
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__18() {
+_start:
+{
+lean_object* x_1; 
+x_1 = lean_mk_string_from_bytes("false", 5);
+return x_1;
+}
+}
+LEAN_EXPORT lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4) {
+_start:
+{
+lean_object* x_5; uint8_t x_6; 
+x_5 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__2;
+lean_inc(x_1);
+x_6 = l_Lean_Syntax_isOfKind(x_1, x_5);
+if (x_6 == 0)
+{
+lean_object* x_7; uint8_t x_8; 
+x_7 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__4;
+lean_inc(x_1);
+x_8 = l_Lean_Syntax_isOfKind(x_1, x_7);
+if (x_8 == 0)
+{
+lean_object* x_9; lean_object* x_10; 
+lean_dec(x_3);
+lean_dec(x_2);
+lean_dec(x_1);
+x_9 = lean_box(0);
+x_10 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_10, 0, x_9);
+lean_ctor_set(x_10, 1, x_4);
+return x_10;
+}
+else
+{
+lean_object* x_11; lean_object* x_12; lean_object* x_13; uint8_t x_14; 
+x_11 = lean_unsigned_to_nat(1u);
+x_12 = l_Lean_Syntax_getArg(x_1, x_11);
+x_13 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__6;
+lean_inc(x_12);
+x_14 = l_Lean_Syntax_isOfKind(x_12, x_13);
+if (x_14 == 0)
+{
+lean_object* x_15; lean_object* x_16; 
+lean_dec(x_12);
+lean_dec(x_3);
+lean_dec(x_2);
+lean_dec(x_1);
+x_15 = lean_box(0);
+x_16 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_16, 0, x_15);
+lean_ctor_set(x_16, 1, x_4);
+return x_16;
+}
+else
+{
+lean_object* x_17; lean_object* x_18; lean_object* x_19; lean_object* x_20; lean_object* x_21; uint8_t x_22; lean_object* x_23; lean_object* x_24; lean_object* x_25; lean_object* x_26; lean_object* x_27; lean_object* x_28; lean_object* x_29; lean_object* x_30; lean_object* x_31; lean_object* x_32; lean_object* x_33; lean_object* x_34; lean_object* x_35; lean_object* x_36; lean_object* x_37; lean_object* x_38; lean_object* x_39; lean_object* x_40; lean_object* x_41; lean_object* x_42; lean_object* x_43; lean_object* x_44; lean_object* x_45; lean_object* x_46; lean_object* x_47; lean_object* x_48; lean_object* x_49; lean_object* x_50; lean_object* x_51; lean_object* x_52; lean_object* x_53; 
+x_17 = lean_unsigned_to_nat(3u);
+x_18 = l_Lean_Syntax_getArg(x_1, x_17);
+x_19 = lean_unsigned_to_nat(5u);
+x_20 = l_Lean_Syntax_getArg(x_1, x_19);
+lean_dec(x_1);
+x_21 = lean_ctor_get(x_3, 5);
+lean_inc(x_21);
+lean_dec(x_3);
+x_22 = 0;
+x_23 = l_Lean_SourceInfo_fromRef(x_21, x_22);
+x_24 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__9;
+lean_inc(x_23);
+x_25 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_25, 0, x_23);
+lean_ctor_set(x_25, 1, x_24);
+x_26 = l_Lean_Elab_Term_Do_mkAuxDeclFor___rarg___lambda__5___closed__2;
+x_27 = l_Lean_Elab_Term_Do_instInhabitedAlt___rarg___closed__1;
+lean_inc(x_23);
+x_28 = lean_alloc_ctor(1, 3, 0);
+lean_ctor_set(x_28, 0, x_23);
+lean_ctor_set(x_28, 1, x_26);
+lean_ctor_set(x_28, 2, x_27);
+x_29 = l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__5___lambda__2___closed__16;
+lean_inc(x_23);
+x_30 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_30, 0, x_23);
+lean_ctor_set(x_30, 1, x_29);
+x_31 = l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__5___lambda__2___closed__19;
+lean_inc(x_23);
+x_32 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_32, 0, x_23);
+lean_ctor_set(x_32, 1, x_31);
+x_33 = l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__5___lambda__2___closed__20;
+lean_inc(x_23);
+x_34 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_34, 0, x_23);
+lean_ctor_set(x_34, 1, x_33);
+x_35 = l_List_redLength___rarg(x_2);
+x_36 = lean_mk_empty_array_with_capacity(x_35);
+lean_dec(x_35);
+x_37 = l_List_toArrayAux___rarg(x_2, x_36);
+x_38 = l_Lean_Elab_Term_Do_mkDoSeq(x_37);
+x_39 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__13;
+lean_inc(x_34);
+lean_inc(x_32);
+lean_inc(x_23);
+x_40 = l_Lean_Syntax_node4(x_23, x_39, x_32, x_12, x_34, x_38);
+lean_inc(x_23);
+x_41 = l_Lean_Syntax_node1(x_23, x_26, x_40);
+x_42 = l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__5___lambda__2___closed__21;
+lean_inc(x_23);
+x_43 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_43, 0, x_23);
+lean_ctor_set(x_43, 1, x_42);
+x_44 = l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_AltExpr_vars___spec__1___closed__2;
+lean_inc(x_23);
+x_45 = l_Lean_Syntax_node1(x_23, x_44, x_43);
+x_46 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__15;
+lean_inc(x_23);
+x_47 = l_Lean_Syntax_node4(x_23, x_46, x_32, x_45, x_34, x_20);
+x_48 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__11;
+lean_inc(x_23);
+x_49 = l_Lean_Syntax_node2(x_23, x_48, x_41, x_47);
+x_50 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__8;
+x_51 = l_Lean_Syntax_node5(x_23, x_50, x_25, x_28, x_18, x_30, x_49);
+x_52 = lean_alloc_ctor(1, 1, 0);
+lean_ctor_set(x_52, 0, x_51);
+x_53 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_53, 0, x_52);
+lean_ctor_set(x_53, 1, x_4);
+return x_53;
+}
+}
+}
+else
+{
+lean_object* x_54; lean_object* x_55; lean_object* x_56; uint8_t x_57; 
+x_54 = lean_unsigned_to_nat(1u);
+x_55 = l_Lean_Syntax_getArg(x_1, x_54);
+x_56 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__6;
+lean_inc(x_55);
+x_57 = l_Lean_Syntax_isOfKind(x_55, x_56);
+if (x_57 == 0)
+{
+lean_object* x_58; lean_object* x_59; 
+lean_dec(x_55);
+lean_dec(x_3);
+lean_dec(x_2);
+lean_dec(x_1);
+x_58 = lean_box(0);
+x_59 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_59, 0, x_58);
+lean_ctor_set(x_59, 1, x_4);
+return x_59;
+}
+else
+{
+lean_object* x_60; lean_object* x_61; lean_object* x_62; lean_object* x_63; lean_object* x_64; uint8_t x_65; lean_object* x_66; lean_object* x_67; lean_object* x_68; lean_object* x_69; lean_object* x_70; lean_object* x_71; lean_object* x_72; lean_object* x_73; lean_object* x_74; lean_object* x_75; lean_object* x_76; lean_object* x_77; lean_object* x_78; lean_object* x_79; lean_object* x_80; lean_object* x_81; lean_object* x_82; lean_object* x_83; lean_object* x_84; lean_object* x_85; lean_object* x_86; lean_object* x_87; lean_object* x_88; lean_object* x_89; lean_object* x_90; lean_object* x_91; lean_object* x_92; lean_object* x_93; lean_object* x_94; lean_object* x_95; lean_object* x_96; lean_object* x_97; lean_object* x_98; lean_object* x_99; lean_object* x_100; lean_object* x_101; lean_object* x_102; lean_object* x_103; lean_object* x_104; lean_object* x_105; 
+x_60 = lean_unsigned_to_nat(3u);
+x_61 = l_Lean_Syntax_getArg(x_1, x_60);
+x_62 = lean_unsigned_to_nat(5u);
+x_63 = l_Lean_Syntax_getArg(x_1, x_62);
+lean_dec(x_1);
+x_64 = lean_ctor_get(x_3, 5);
+lean_inc(x_64);
+lean_dec(x_3);
+x_65 = 0;
+x_66 = l_Lean_SourceInfo_fromRef(x_64, x_65);
+x_67 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__9;
+lean_inc(x_66);
+x_68 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_68, 0, x_66);
+lean_ctor_set(x_68, 1, x_67);
+x_69 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkUnit___closed__3;
+lean_inc(x_66);
+x_70 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_70, 0, x_66);
+lean_ctor_set(x_70, 1, x_69);
+x_71 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__16;
+lean_inc(x_66);
+x_72 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_72, 0, x_66);
+lean_ctor_set(x_72, 1, x_71);
+x_73 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
+lean_inc(x_66);
+x_74 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_74, 0, x_66);
+lean_ctor_set(x_74, 1, x_73);
+x_75 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__18;
+lean_inc(x_66);
+x_76 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_76, 0, x_66);
+lean_ctor_set(x_76, 1, x_75);
+x_77 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkUnit___closed__16;
+lean_inc(x_66);
+x_78 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_78, 0, x_66);
+lean_ctor_set(x_78, 1, x_77);
+x_79 = l_Lean_Elab_Term_Do_mkAuxDeclFor___rarg___lambda__5___closed__2;
+lean_inc(x_66);
+x_80 = l_Lean_Syntax_node5(x_66, x_79, x_70, x_72, x_74, x_76, x_78);
+x_81 = l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__5___lambda__2___closed__16;
+lean_inc(x_66);
+x_82 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_82, 0, x_66);
+lean_ctor_set(x_82, 1, x_81);
+x_83 = l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__5___lambda__2___closed__19;
+lean_inc(x_66);
+x_84 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_84, 0, x_66);
+lean_ctor_set(x_84, 1, x_83);
+x_85 = l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__5___lambda__2___closed__20;
+lean_inc(x_66);
+x_86 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_86, 0, x_66);
+lean_ctor_set(x_86, 1, x_85);
+x_87 = l_List_redLength___rarg(x_2);
+x_88 = lean_mk_empty_array_with_capacity(x_87);
+lean_dec(x_87);
+x_89 = l_List_toArrayAux___rarg(x_2, x_88);
+x_90 = l_Lean_Elab_Term_Do_mkDoSeq(x_89);
+x_91 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__13;
+lean_inc(x_86);
+lean_inc(x_84);
+lean_inc(x_66);
+x_92 = l_Lean_Syntax_node4(x_66, x_91, x_84, x_55, x_86, x_90);
+lean_inc(x_66);
+x_93 = l_Lean_Syntax_node1(x_66, x_79, x_92);
+x_94 = l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__5___lambda__2___closed__21;
+lean_inc(x_66);
+x_95 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_95, 0, x_66);
+lean_ctor_set(x_95, 1, x_94);
+x_96 = l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_AltExpr_vars___spec__1___closed__2;
+lean_inc(x_66);
+x_97 = l_Lean_Syntax_node1(x_66, x_96, x_95);
+x_98 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__15;
+lean_inc(x_66);
+x_99 = l_Lean_Syntax_node4(x_66, x_98, x_84, x_97, x_86, x_63);
+x_100 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__11;
+lean_inc(x_66);
+x_101 = l_Lean_Syntax_node2(x_66, x_100, x_93, x_99);
+x_102 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__8;
+x_103 = l_Lean_Syntax_node5(x_66, x_102, x_68, x_80, x_61, x_82, x_101);
+x_104 = lean_alloc_ctor(1, 1, 0);
+lean_ctor_set(x_104, 0, x_103);
+x_105 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_105, 0, x_104);
+lean_ctor_set(x_105, 1, x_4);
+return x_105;
+}
+}
+}
+}
 LEAN_EXPORT lean_object* l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkDoIfView(lean_object* x_1) {
 _start:
 {
@@ -18247,7 +18669,7 @@
 lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; lean_object* x_6; 
 x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__1;
 x_2 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__2;
-x_3 = lean_unsigned_to_nat(842u);
+x_3 = lean_unsigned_to_nat(855u);
 x_4 = lean_unsigned_to_nat(13u);
 x_5 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__3;
 x_6 = l___private_Init_Util_0__mkPanicMessageWithDecl(x_1, x_2, x_3, x_4, x_5);
@@ -18305,31 +18727,23 @@
 _start:
 {
 lean_object* x_1; 
-x_1 = lean_mk_string_from_bytes(":=", 2);
+x_1 = lean_mk_string_from_bytes("proj", 4);
 return x_1;
 }
 }
 static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__11() {
 _start:
 {
-lean_object* x_1; 
-x_1 = lean_mk_string_from_bytes("proj", 4);
-return x_1;
-}
-}
-static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12() {
-_start:
-{
 lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; 
 x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__1;
 x_2 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__2;
 x_3 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__3;
-x_4 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__11;
+x_4 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
 x_5 = l_Lean_Name_mkStr4(x_1, x_2, x_3, x_4);
 return x_5;
 }
 }
-static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__13() {
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12() {
 _start:
 {
 lean_object* x_1; 
@@ -18337,7 +18751,7 @@
 return x_1;
 }
 }
-static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__14() {
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__13() {
 _start:
 {
 lean_object* x_1; 
@@ -18345,17 +18759,17 @@
 return x_1;
 }
 }
-static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__15() {
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__14() {
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
 x_1 = lean_box(0);
-x_2 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__14;
+x_2 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__13;
 x_3 = l_Lean_Name_str___override(x_1, x_2);
 return x_3;
 }
 }
-static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16() {
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__15() {
 _start:
 {
 lean_object* x_1; 
@@ -18363,7 +18777,7 @@
 return x_1;
 }
 }
-static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17() {
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16() {
 _start:
 {
 lean_object* x_1; 
@@ -18371,7 +18785,7 @@
 return x_1;
 }
 }
-static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__18() {
+static lean_object* _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17() {
 _start:
 {
 lean_object* x_1; 
@@ -18467,25 +18881,25 @@
 lean_ctor_set(x_35, 0, x_22);
 lean_ctor_set(x_35, 1, x_33);
 lean_ctor_set(x_35, 2, x_34);
-x_36 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_36 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_22);
 x_37 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_37, 0, x_22);
 lean_ctor_set(x_37, 1, x_36);
-x_38 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__13;
+x_38 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
 lean_inc(x_22);
 x_39 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_39, 0, x_22);
 lean_ctor_set(x_39, 1, x_38);
-x_40 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
+x_40 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__15;
 lean_inc(x_22);
 x_41 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_41, 0, x_22);
 lean_ctor_set(x_41, 1, x_40);
-x_42 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__15;
+x_42 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__14;
 lean_inc(x_22);
 x_43 = l_Lean_Syntax_node1(x_22, x_42, x_41);
-x_44 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
+x_44 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__11;
 lean_inc(x_39);
 lean_inc(x_2);
 lean_inc(x_22);
@@ -18498,12 +18912,12 @@
 x_48 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__9;
 lean_inc(x_22);
 x_49 = l_Lean_Syntax_node1(x_22, x_48, x_47);
-x_50 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_50 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_22);
 x_51 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_51, 0, x_22);
 lean_ctor_set(x_51, 1, x_50);
-x_52 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__18;
+x_52 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
 lean_inc(x_22);
 x_53 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_53, 0, x_22);
@@ -18577,25 +18991,25 @@
 lean_ctor_set(x_75, 0, x_70);
 lean_ctor_set(x_75, 1, x_73);
 lean_ctor_set(x_75, 2, x_74);
-x_76 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_76 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_70);
 x_77 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_77, 0, x_70);
 lean_ctor_set(x_77, 1, x_76);
-x_78 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__13;
+x_78 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
 lean_inc(x_70);
 x_79 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_79, 0, x_70);
 lean_ctor_set(x_79, 1, x_78);
-x_80 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
+x_80 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__15;
 lean_inc(x_70);
 x_81 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_81, 0, x_70);
 lean_ctor_set(x_81, 1, x_80);
-x_82 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__15;
+x_82 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__14;
 lean_inc(x_70);
 x_83 = l_Lean_Syntax_node1(x_70, x_82, x_81);
-x_84 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
+x_84 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__11;
 lean_inc(x_79);
 lean_inc(x_2);
 lean_inc(x_70);
@@ -18608,12 +19022,12 @@
 x_88 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__9;
 lean_inc(x_70);
 x_89 = l_Lean_Syntax_node1(x_70, x_88, x_87);
-x_90 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_90 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_70);
 x_91 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_91, 0, x_70);
 lean_ctor_set(x_91, 1, x_90);
-x_92 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__18;
+x_92 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
 lean_inc(x_70);
 x_93 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_93, 0, x_70);
@@ -18710,25 +19124,25 @@
 lean_ctor_set(x_128, 0, x_115);
 lean_ctor_set(x_128, 1, x_126);
 lean_ctor_set(x_128, 2, x_127);
-x_129 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_129 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_115);
 x_130 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_130, 0, x_115);
 lean_ctor_set(x_130, 1, x_129);
-x_131 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__13;
+x_131 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
 lean_inc(x_115);
 x_132 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_132, 0, x_115);
 lean_ctor_set(x_132, 1, x_131);
-x_133 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
+x_133 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__15;
 lean_inc(x_115);
 x_134 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_134, 0, x_115);
 lean_ctor_set(x_134, 1, x_133);
-x_135 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__15;
+x_135 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__14;
 lean_inc(x_115);
 x_136 = l_Lean_Syntax_node1(x_115, x_135, x_134);
-x_137 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
+x_137 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__11;
 lean_inc(x_132);
 lean_inc(x_2);
 lean_inc(x_115);
@@ -18741,12 +19155,12 @@
 x_141 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__9;
 lean_inc(x_115);
 x_142 = l_Lean_Syntax_node1(x_115, x_141, x_140);
-x_143 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_143 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_115);
 x_144 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_144, 0, x_115);
 lean_ctor_set(x_144, 1, x_143);
-x_145 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__18;
+x_145 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
 lean_inc(x_115);
 x_146 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_146, 0, x_115);
@@ -18835,12 +19249,12 @@
 lean_ctor_set(x_21, 0, x_15);
 lean_ctor_set(x_21, 1, x_19);
 lean_ctor_set(x_21, 2, x_20);
-x_22 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_22 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_15);
 x_23 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_23, 0, x_15);
 lean_ctor_set(x_23, 1, x_22);
-x_24 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_24 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_15);
 x_25 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_25, 0, x_15);
@@ -19436,7 +19850,7 @@
 lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; lean_object* x_6; 
 x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__1;
 x_2 = l_Lean_Elab_Term_Do_ToTerm_returnToTerm___closed__21;
-x_3 = lean_unsigned_to_nat(986u);
+x_3 = lean_unsigned_to_nat(999u);
 x_4 = lean_unsigned_to_nat(24u);
 x_5 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__3;
 x_6 = l___private_Init_Util_0__mkPanicMessageWithDecl(x_1, x_2, x_3, x_4, x_5);
@@ -20223,7 +20637,7 @@
 lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; lean_object* x_6; 
 x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__1;
 x_2 = l_Lean_Elab_Term_Do_ToTerm_continueToTerm___closed__1;
-x_3 = lean_unsigned_to_nat(995u);
+x_3 = lean_unsigned_to_nat(1008u);
 x_4 = lean_unsigned_to_nat(24u);
 x_5 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__3;
 x_6 = l___private_Init_Util_0__mkPanicMessageWithDecl(x_1, x_2, x_3, x_4, x_5);
@@ -20467,7 +20881,7 @@
 lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; lean_object* x_6; 
 x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__1;
 x_2 = l_Lean_Elab_Term_Do_ToTerm_continueToTerm___closed__1;
-x_3 = lean_unsigned_to_nat(999u);
+x_3 = lean_unsigned_to_nat(1012u);
 x_4 = lean_unsigned_to_nat(24u);
 x_5 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__3;
 x_6 = l___private_Init_Util_0__mkPanicMessageWithDecl(x_1, x_2, x_3, x_4, x_5);
@@ -21033,7 +21447,7 @@
 lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; lean_object* x_6; 
 x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__1;
 x_2 = l_Lean_Elab_Term_Do_ToTerm_breakToTerm___closed__1;
-x_3 = lean_unsigned_to_nat(1007u);
+x_3 = lean_unsigned_to_nat(1020u);
 x_4 = lean_unsigned_to_nat(24u);
 x_5 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__3;
 x_6 = l___private_Init_Util_0__mkPanicMessageWithDecl(x_1, x_2, x_3, x_4, x_5);
@@ -21127,7 +21541,7 @@
 lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; lean_object* x_6; 
 x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__1;
 x_2 = l_Lean_Elab_Term_Do_ToTerm_breakToTerm___closed__1;
-x_3 = lean_unsigned_to_nat(1011u);
+x_3 = lean_unsigned_to_nat(1024u);
 x_4 = lean_unsigned_to_nat(24u);
 x_5 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__3;
 x_6 = l___private_Init_Util_0__mkPanicMessageWithDecl(x_1, x_2, x_3, x_4, x_5);
@@ -21796,7 +22210,7 @@
 lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; lean_object* x_6; 
 x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__1;
 x_2 = l_Lean_Elab_Term_Do_ToTerm_actionTerminalToTerm___closed__11;
-x_3 = lean_unsigned_to_nat(1022u);
+x_3 = lean_unsigned_to_nat(1035u);
 x_4 = lean_unsigned_to_nat(24u);
 x_5 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__3;
 x_6 = l___private_Init_Util_0__mkPanicMessageWithDecl(x_1, x_2, x_3, x_4, x_5);
@@ -23085,7 +23499,7 @@
 x_77 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_77, 0, x_75);
 lean_ctor_set(x_77, 1, x_76);
-x_78 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_78 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_75);
 x_79 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_79, 0, x_75);
@@ -23114,7 +23528,7 @@
 x_87 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_87, 0, x_85);
 lean_ctor_set(x_87, 1, x_86);
-x_88 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_88 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_85);
 x_89 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_89, 0, x_85);
@@ -23489,7 +23903,7 @@
 x_116 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_116, 0, x_114);
 lean_ctor_set(x_116, 1, x_115);
-x_117 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_117 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_114);
 x_118 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_118, 0, x_114);
@@ -23722,7 +24136,7 @@
 lean_ctor_set(x_47, 0, x_42);
 lean_ctor_set(x_47, 1, x_45);
 lean_ctor_set(x_47, 2, x_46);
-x_48 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_48 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_42);
 x_49 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_49, 0, x_42);
@@ -23743,7 +24157,7 @@
 x_56 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__9;
 lean_inc(x_42);
 x_57 = l_Lean_Syntax_node1(x_42, x_56, x_55);
-x_58 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_58 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_42);
 x_59 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_59, 0, x_42);
@@ -23834,7 +24248,7 @@
 lean_ctor_set(x_85, 0, x_80);
 lean_ctor_set(x_85, 1, x_83);
 lean_ctor_set(x_85, 2, x_84);
-x_86 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_86 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_80);
 x_87 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_87, 0, x_80);
@@ -23855,7 +24269,7 @@
 x_94 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__9;
 lean_inc(x_80);
 x_95 = l_Lean_Syntax_node1(x_80, x_94, x_93);
-x_96 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_96 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_80);
 x_97 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_97, 0, x_80);
@@ -24387,7 +24801,7 @@
 x_53 = l_Lean_Syntax_node2(x_31, x_52, x_43, x_51);
 lean_inc(x_31);
 x_54 = l_Lean_Syntax_node1(x_31, x_37, x_53);
-x_55 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_55 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_31);
 x_56 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_56, 0, x_31);
@@ -24398,7 +24812,7 @@
 x_59 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__9;
 lean_inc(x_31);
 x_60 = l_Lean_Syntax_node1(x_31, x_59, x_58);
-x_61 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_61 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_31);
 x_62 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_62, 0, x_31);
@@ -24571,53 +24985,13 @@
 static lean_object* _init_l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__1() {
 _start:
 {
-lean_object* x_1; 
-x_1 = lean_mk_string_from_bytes("matchExprPat", 12);
-return x_1;
-}
-}
-static lean_object* _init_l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__2() {
-_start:
-{
-lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; 
-x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__1;
-x_2 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__2;
-x_3 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__3;
-x_4 = l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__1;
-x_5 = l_Lean_Name_mkStr4(x_1, x_2, x_3, x_4);
-return x_5;
-}
-}
-static lean_object* _init_l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__3() {
-_start:
-{
 lean_object* x_1; lean_object* x_2; 
 x_1 = lean_unsigned_to_nat(3u);
 x_2 = lean_mk_empty_array_with_capacity(x_1);
 return x_2;
 }
 }
-static lean_object* _init_l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__4() {
-_start:
-{
-lean_object* x_1; 
-x_1 = lean_mk_string_from_bytes("matchExprAlt", 12);
-return x_1;
-}
-}
-static lean_object* _init_l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__5() {
-_start:
-{
-lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; 
-x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__1;
-x_2 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__2;
-x_3 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__3;
-x_4 = l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__4;
-x_5 = l_Lean_Name_mkStr4(x_1, x_2, x_3, x_4);
-return x_5;
-}
-}
-static lean_object* _init_l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__6() {
+static lean_object* _init_l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__2() {
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; 
@@ -24631,12 +25005,12 @@
 return x_4;
 }
 }
-static lean_object* _init_l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__7() {
+static lean_object* _init_l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__3() {
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__3;
-x_2 = l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__6;
+x_1 = l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__1;
+x_2 = l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__2;
 x_3 = lean_array_push(x_1, x_2);
 return x_3;
 }
@@ -24699,10 +25073,10 @@
 if (lean_obj_tag(x_15) == 0)
 {
 lean_object* x_29; lean_object* x_30; lean_object* x_31; lean_object* x_32; lean_object* x_33; lean_object* x_34; lean_object* x_35; lean_object* x_36; lean_object* x_37; lean_object* x_38; lean_object* x_39; size_t x_40; size_t x_41; 
-x_29 = l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__7;
+x_29 = l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__3;
 x_30 = lean_array_push(x_29, x_16);
 x_31 = lean_array_push(x_30, x_20);
-x_32 = l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__2;
+x_32 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__6;
 x_33 = lean_alloc_ctor(1, 3, 0);
 lean_ctor_set(x_33, 0, x_18);
 lean_ctor_set(x_33, 1, x_32);
@@ -24710,7 +25084,7 @@
 x_34 = lean_array_push(x_28, x_33);
 x_35 = lean_array_push(x_34, x_26);
 x_36 = lean_array_push(x_35, x_13);
-x_37 = l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__5;
+x_37 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__13;
 x_38 = lean_alloc_ctor(1, 3, 0);
 lean_ctor_set(x_38, 0, x_18);
 lean_ctor_set(x_38, 1, x_37);
@@ -24739,11 +25113,11 @@
 lean_ctor_set(x_49, 0, x_18);
 lean_ctor_set(x_49, 1, x_19);
 lean_ctor_set(x_49, 2, x_48);
-x_50 = l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__3;
+x_50 = l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__1;
 x_51 = lean_array_push(x_50, x_49);
 x_52 = lean_array_push(x_51, x_16);
 x_53 = lean_array_push(x_52, x_20);
-x_54 = l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__2;
+x_54 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__6;
 x_55 = lean_alloc_ctor(1, 3, 0);
 lean_ctor_set(x_55, 0, x_18);
 lean_ctor_set(x_55, 1, x_54);
@@ -24751,7 +25125,7 @@
 x_56 = lean_array_push(x_28, x_55);
 x_57 = lean_array_push(x_56, x_26);
 x_58 = lean_array_push(x_57, x_13);
-x_59 = l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__5;
+x_59 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__13;
 x_60 = lean_alloc_ctor(1, 3, 0);
 lean_ctor_set(x_60, 0, x_18);
 lean_ctor_set(x_60, 1, x_59);
@@ -24837,7 +25211,7 @@
 _start:
 {
 lean_object* x_1; 
-x_1 = lean_mk_string_from_bytes("matchExprElseAlt", 16);
+x_1 = lean_mk_string_from_bytes("matchExpr", 9);
 return x_1;
 }
 }
@@ -24857,64 +25231,67 @@
 _start:
 {
 lean_object* x_1; 
-x_1 = lean_mk_string_from_bytes("matchExprAlts", 13);
+x_1 = lean_mk_string_from_bytes("instantiateMVarsIfMVarApp", 25);
 return x_1;
 }
 }
 static lean_object* _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__9() {
 _start:
 {
-lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; 
-x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__1;
-x_2 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__2;
-x_3 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__3;
-x_4 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__8;
-x_5 = l_Lean_Name_mkStr4(x_1, x_2, x_3, x_4);
-return x_5;
+lean_object* x_1; lean_object* x_2; 
+x_1 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__8;
+x_2 = l_String_toSubstring_x27(x_1);
+return x_2;
 }
 }
 static lean_object* _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__10() {
 _start:
 {
-lean_object* x_1; 
-x_1 = lean_mk_string_from_bytes("matchExpr", 9);
-return x_1;
+lean_object* x_1; lean_object* x_2; lean_object* x_3; 
+x_1 = lean_box(0);
+x_2 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__8;
+x_3 = l_Lean_Name_str___override(x_1, x_2);
+return x_3;
 }
 }
 static lean_object* _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__11() {
 _start:
 {
-lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; 
-x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__1;
-x_2 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__2;
-x_3 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__3;
-x_4 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__10;
-x_5 = l_Lean_Name_mkStr4(x_1, x_2, x_3, x_4);
-return x_5;
+lean_object* x_1; 
+x_1 = lean_mk_string_from_bytes("Meta", 4);
+return x_1;
 }
 }
 static lean_object* _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__12() {
 _start:
 {
-lean_object* x_1; 
-x_1 = lean_mk_string_from_bytes("match_expr", 10);
-return x_1;
+lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; 
+x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__1;
+x_2 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__11;
+x_3 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__8;
+x_4 = l_Lean_Name_mkStr3(x_1, x_2, x_3);
+return x_4;
 }
 }
 static lean_object* _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__13() {
 _start:
 {
-lean_object* x_1; 
-x_1 = lean_mk_string_from_bytes("instantiateMVarsIfMVarApp", 25);
-return x_1;
+lean_object* x_1; lean_object* x_2; lean_object* x_3; 
+x_1 = lean_box(0);
+x_2 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__12;
+x_3 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_3, 0, x_2);
+lean_ctor_set(x_3, 1, x_1);
+return x_3;
 }
 }
 static lean_object* _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__14() {
 _start:
 {
 lean_object* x_1; lean_object* x_2; 
-x_1 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__13;
-x_2 = l_String_toSubstring_x27(x_1);
+x_1 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__12;
+x_2 = lean_alloc_ctor(0, 1, 0);
+lean_ctor_set(x_2, 0, x_1);
 return x_2;
 }
 }
@@ -24923,70 +25300,19 @@
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
 x_1 = lean_box(0);
-x_2 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__13;
-x_3 = l_Lean_Name_str___override(x_1, x_2);
+x_2 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__14;
+x_3 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_3, 0, x_2);
+lean_ctor_set(x_3, 1, x_1);
 return x_3;
 }
 }
 static lean_object* _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__16() {
 _start:
 {
-lean_object* x_1; 
-x_1 = lean_mk_string_from_bytes("Meta", 4);
-return x_1;
-}
-}
-static lean_object* _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__17() {
-_start:
-{
-lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; 
-x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__1;
-x_2 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__16;
-x_3 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__13;
-x_4 = l_Lean_Name_mkStr3(x_1, x_2, x_3);
-return x_4;
-}
-}
-static lean_object* _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__18() {
-_start:
-{
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_box(0);
-x_2 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__17;
-x_3 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_3, 0, x_2);
-lean_ctor_set(x_3, 1, x_1);
-return x_3;
-}
-}
-static lean_object* _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__19() {
-_start:
-{
-lean_object* x_1; lean_object* x_2; 
-x_1 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__17;
-x_2 = lean_alloc_ctor(0, 1, 0);
-lean_ctor_set(x_2, 0, x_1);
-return x_2;
-}
-}
-static lean_object* _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__20() {
-_start:
-{
-lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_box(0);
-x_2 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__19;
-x_3 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_3, 0, x_2);
-lean_ctor_set(x_3, 1, x_1);
-return x_3;
-}
-}
-static lean_object* _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__21() {
-_start:
-{
-lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__18;
-x_2 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__20;
+x_1 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__13;
+x_2 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__15;
 x_3 = lean_alloc_ctor(1, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
 lean_ctor_set(x_3, 1, x_2);
@@ -25578,7 +25904,7 @@
 x_186 = lean_array_push(x_185, x_182);
 x_187 = lean_array_push(x_186, x_176);
 x_188 = lean_box(2);
-x_189 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__7;
+x_189 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__15;
 x_190 = lean_alloc_ctor(1, 3, 0);
 lean_ctor_set(x_190, 0, x_188);
 lean_ctor_set(x_190, 1, x_189);
@@ -25591,12 +25917,12 @@
 x_193 = l_Array_mapMUnsafe_map___at_Lean_Elab_Term_Do_mkDoSeq___spec__1___closed__1;
 x_194 = lean_array_push(x_193, x_192);
 x_195 = lean_array_push(x_194, x_190);
-x_196 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__9;
+x_196 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__11;
 x_197 = lean_alloc_ctor(1, 3, 0);
 lean_ctor_set(x_197, 0, x_188);
 lean_ctor_set(x_197, 1, x_196);
 lean_ctor_set(x_197, 2, x_195);
-x_198 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__12;
+x_198 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__9;
 lean_inc(x_145);
 x_199 = l_Lean_mkAtomFrom(x_145, x_198, x_161);
 x_200 = l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__5___lambda__2___closed__16;
@@ -25606,7 +25932,7 @@
 x_203 = lean_array_push(x_202, x_167);
 x_204 = lean_array_push(x_203, x_201);
 x_205 = lean_array_push(x_204, x_197);
-x_206 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__11;
+x_206 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__7;
 x_207 = lean_alloc_ctor(1, 3, 0);
 lean_ctor_set(x_207, 0, x_188);
 lean_ctor_set(x_207, 1, x_206);
@@ -25626,7 +25952,7 @@
 lean_ctor_set(x_210, 0, x_162);
 lean_ctor_set(x_210, 1, x_191);
 lean_ctor_set(x_210, 2, x_171);
-x_211 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_211 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_162);
 x_212 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_212, 0, x_162);
@@ -25638,7 +25964,7 @@
 x_215 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__9;
 lean_inc(x_162);
 x_216 = l_Lean_Syntax_node1(x_162, x_215, x_214);
-x_217 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_217 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_162);
 x_218 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_218, 0, x_162);
@@ -25670,10 +25996,10 @@
 x_228 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_228, 0, x_162);
 lean_ctor_set(x_228, 1, x_227);
-x_229 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__15;
+x_229 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__10;
 x_230 = l_Lean_addMacroScope(x_156, x_229, x_150);
-x_231 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__14;
-x_232 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__21;
+x_231 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__9;
+x_232 = l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__16;
 lean_inc(x_162);
 x_233 = lean_alloc_ctor(3, 4, 0);
 lean_ctor_set(x_233, 0, x_162);
@@ -25951,7 +26277,7 @@
 lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; lean_object* x_6; 
 x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__1;
 x_2 = l_Lean_Elab_Term_Do_ToTerm_mkNestedKind___closed__1;
-x_3 = lean_unsigned_to_nat(1178u);
+x_3 = lean_unsigned_to_nat(1191u);
 x_4 = lean_unsigned_to_nat(27u);
 x_5 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__3;
 x_6 = l___private_Init_Util_0__mkPanicMessageWithDecl(x_1, x_2, x_3, x_4, x_5);
@@ -26120,7 +26446,7 @@
 lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; lean_object* x_6; 
 x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__1;
 x_2 = l_Lean_Elab_Term_Do_ToTerm_matchNestedTermResult___closed__1;
-x_3 = lean_unsigned_to_nat(1234u);
+x_3 = lean_unsigned_to_nat(1247u);
 x_4 = lean_unsigned_to_nat(27u);
 x_5 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__3;
 x_6 = l___private_Init_Util_0__mkPanicMessageWithDecl(x_1, x_2, x_3, x_4, x_5);
@@ -26477,7 +26803,7 @@
 lean_inc(x_25);
 lean_inc(x_16);
 x_38 = l_Lean_Syntax_node3(x_16, x_37, x_22, x_25, x_36);
-x_39 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_39 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_16);
 x_40 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_40, 0, x_16);
@@ -26509,7 +26835,7 @@
 x_52 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_52, 0, x_16);
 lean_ctor_set(x_52, 1, x_51);
-x_53 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__13;
+x_53 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
 lean_inc(x_16);
 x_54 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_54, 0, x_16);
@@ -26556,7 +26882,7 @@
 x_71 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_71, 0, x_16);
 lean_ctor_set(x_71, 1, x_70);
-x_72 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_72 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_16);
 x_73 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_73, 0, x_16);
@@ -26721,7 +27047,7 @@
 lean_inc(x_133);
 lean_inc(x_124);
 x_146 = l_Lean_Syntax_node3(x_124, x_145, x_130, x_133, x_144);
-x_147 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_147 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_124);
 x_148 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_148, 0, x_124);
@@ -26732,25 +27058,25 @@
 lean_inc(x_149);
 lean_inc(x_124);
 x_151 = l_Lean_Syntax_node2(x_124, x_150, x_146, x_149);
-x_152 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_152 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_124);
 x_153 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_153, 0, x_124);
 lean_ctor_set(x_153, 1, x_152);
-x_154 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__13;
+x_154 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
 lean_inc(x_124);
 x_155 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_155, 0, x_124);
 lean_ctor_set(x_155, 1, x_154);
-x_156 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__18;
+x_156 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
 lean_inc(x_124);
 x_157 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_157, 0, x_124);
 lean_ctor_set(x_157, 1, x_156);
-x_158 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__15;
+x_158 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__14;
 lean_inc(x_124);
 x_159 = l_Lean_Syntax_node1(x_124, x_158, x_157);
-x_160 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
+x_160 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__11;
 lean_inc(x_155);
 lean_inc(x_138);
 lean_inc(x_124);
@@ -26769,7 +27095,7 @@
 x_168 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_168, 0, x_124);
 lean_ctor_set(x_168, 1, x_167);
-x_169 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
+x_169 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__15;
 lean_inc(x_124);
 x_170 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_170, 0, x_124);
@@ -26858,7 +27184,7 @@
 lean_inc(x_197);
 lean_inc(x_188);
 x_210 = l_Lean_Syntax_node3(x_188, x_209, x_194, x_197, x_208);
-x_211 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_211 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_188);
 x_212 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_212, 0, x_188);
@@ -26961,7 +27287,7 @@
 lean_inc(x_244);
 lean_inc(x_235);
 x_257 = l_Lean_Syntax_node3(x_235, x_256, x_241, x_244, x_255);
-x_258 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_258 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_235);
 x_259 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_259, 0, x_235);
@@ -26993,7 +27319,7 @@
 x_271 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_271, 0, x_235);
 lean_ctor_set(x_271, 1, x_270);
-x_272 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__13;
+x_272 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
 lean_inc(x_235);
 x_273 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_273, 0, x_235);
@@ -27051,7 +27377,7 @@
 x_294 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_294, 0, x_235);
 lean_ctor_set(x_294, 1, x_293);
-x_295 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_295 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_235);
 x_296 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_296, 0, x_235);
@@ -27267,7 +27593,7 @@
 lean_inc(x_374);
 lean_inc(x_365);
 x_387 = l_Lean_Syntax_node3(x_365, x_386, x_371, x_374, x_385);
-x_388 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_388 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_365);
 x_389 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_389, 0, x_365);
@@ -27278,25 +27604,25 @@
 lean_inc(x_390);
 lean_inc(x_365);
 x_392 = l_Lean_Syntax_node2(x_365, x_391, x_387, x_390);
-x_393 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_393 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_365);
 x_394 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_394, 0, x_365);
 lean_ctor_set(x_394, 1, x_393);
-x_395 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__13;
+x_395 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
 lean_inc(x_365);
 x_396 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_396, 0, x_365);
 lean_ctor_set(x_396, 1, x_395);
-x_397 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__18;
+x_397 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
 lean_inc(x_365);
 x_398 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_398, 0, x_365);
 lean_ctor_set(x_398, 1, x_397);
-x_399 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__15;
+x_399 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__14;
 lean_inc(x_365);
 x_400 = l_Lean_Syntax_node1(x_365, x_399, x_398);
-x_401 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
+x_401 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__11;
 lean_inc(x_396);
 lean_inc(x_379);
 lean_inc(x_365);
@@ -27320,7 +27646,7 @@
 lean_ctor_set(x_412, 1, x_410);
 lean_ctor_set(x_412, 2, x_409);
 lean_ctor_set(x_412, 3, x_411);
-x_413 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
+x_413 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__15;
 lean_inc(x_365);
 x_414 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_414, 0, x_365);
@@ -27462,7 +27788,7 @@
 lean_inc(x_465);
 lean_inc(x_456);
 x_478 = l_Lean_Syntax_node3(x_456, x_477, x_462, x_465, x_476);
-x_479 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_479 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_456);
 x_480 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_480, 0, x_456);
@@ -27494,7 +27820,7 @@
 x_492 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_492, 0, x_456);
 lean_ctor_set(x_492, 1, x_491);
-x_493 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__13;
+x_493 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
 lean_inc(x_456);
 x_494 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_494, 0, x_456);
@@ -27552,7 +27878,7 @@
 x_515 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_515, 0, x_456);
 lean_ctor_set(x_515, 1, x_514);
-x_516 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_516 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_456);
 x_517 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_517, 0, x_456);
@@ -27769,7 +28095,7 @@
 lean_inc(x_597);
 lean_inc(x_588);
 x_610 = l_Lean_Syntax_node3(x_588, x_609, x_594, x_597, x_608);
-x_611 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_611 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_588);
 x_612 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_612, 0, x_588);
@@ -27801,7 +28127,7 @@
 x_624 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_624, 0, x_588);
 lean_ctor_set(x_624, 1, x_623);
-x_625 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__13;
+x_625 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
 lean_inc(x_588);
 x_626 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_626, 0, x_588);
@@ -27861,7 +28187,7 @@
 x_648 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_648, 0, x_588);
 lean_ctor_set(x_648, 1, x_647);
-x_649 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_649 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_588);
 x_650 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_650, 0, x_588);
@@ -28035,7 +28361,7 @@
 lean_inc(x_714);
 lean_inc(x_705);
 x_727 = l_Lean_Syntax_node3(x_705, x_726, x_711, x_714, x_725);
-x_728 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_728 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_705);
 x_729 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_729, 0, x_705);
@@ -28067,7 +28393,7 @@
 x_741 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_741, 0, x_705);
 lean_ctor_set(x_741, 1, x_740);
-x_742 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__13;
+x_742 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
 lean_inc(x_705);
 x_743 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_743, 0, x_705);
@@ -28128,7 +28454,7 @@
 x_765 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_765, 0, x_705);
 lean_ctor_set(x_765, 1, x_764);
-x_766 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_766 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_705);
 x_767 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_767, 0, x_705);
@@ -33340,7 +33666,7 @@
 _start:
 {
 lean_object* x_1; 
-x_1 = lean_mk_string_from_bytes("doMatchExpr", 11);
+x_1 = lean_mk_string_from_bytes("doTry", 5);
 return x_1;
 }
 }
@@ -33360,7 +33686,7 @@
 _start:
 {
 lean_object* x_1; 
-x_1 = lean_mk_string_from_bytes("doTry", 5);
+x_1 = lean_mk_string_from_bytes("doNested", 8);
 return x_1;
 }
 }
@@ -33380,27 +33706,24 @@
 _start:
 {
 lean_object* x_1; 
-x_1 = lean_mk_string_from_bytes("doNested", 8);
+x_1 = lean_mk_string_from_bytes("unexpected do-element of kind ", 30);
 return x_1;
 }
 }
 static lean_object* _init_l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__12() {
 _start:
 {
-lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; 
-x_1 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__1;
-x_2 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__2;
-x_3 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__3;
-x_4 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__11;
-x_5 = l_Lean_Name_mkStr4(x_1, x_2, x_3, x_4);
-return x_5;
+lean_object* x_1; lean_object* x_2; 
+x_1 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__11;
+x_2 = l_Lean_stringToMessageData(x_1);
+return x_2;
 }
 }
 static lean_object* _init_l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__13() {
 _start:
 {
 lean_object* x_1; 
-x_1 = lean_mk_string_from_bytes("unexpected do-element of kind ", 30);
+x_1 = lean_mk_string_from_bytes(":\n", 2);
 return x_1;
 }
 }
@@ -33413,23 +33736,6 @@
 return x_2;
 }
 }
-static lean_object* _init_l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__15() {
-_start:
-{
-lean_object* x_1; 
-x_1 = lean_mk_string_from_bytes(":\n", 2);
-return x_1;
-}
-}
-static lean_object* _init_l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__16() {
-_start:
-{
-lean_object* x_1; lean_object* x_2; 
-x_1 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__15;
-x_2 = l_Lean_stringToMessageData(x_1);
-return x_2;
-}
-}
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6, lean_object* x_7, lean_object* x_8, lean_object* x_9) {
 _start:
 {
@@ -33542,10 +33848,15 @@
 lean_inc(x_40);
 if (lean_obj_tag(x_40) == 0)
 {
-lean_object* x_41; lean_object* x_42; 
+lean_object* x_41; lean_object* x_42; lean_object* x_43; 
 x_41 = lean_ctor_get(x_39, 1);
 lean_inc(x_41);
 lean_dec(x_39);
+lean_inc(x_13);
+lean_inc(x_12);
+x_42 = lean_alloc_closure((void*)(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f), 4, 2);
+lean_closure_set(x_42, 0, x_12);
+lean_closure_set(x_42, 1, x_13);
 lean_inc(x_8);
 lean_inc(x_30);
 lean_inc(x_6);
@@ -33553,160 +33864,179 @@
 lean_inc(x_4);
 lean_inc(x_3);
 lean_inc(x_2);
-x_42 = l_Lean_Elab_Term_Do_ToCodeBlock_expandLiftMethod(x_12, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_41);
-if (lean_obj_tag(x_42) == 0)
+x_43 = l_Lean_Elab_liftMacroM___at_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___spec__6(x_42, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_41);
+if (lean_obj_tag(x_43) == 0)
 {
-lean_object* x_43; lean_object* x_44; lean_object* x_45; lean_object* x_46; uint8_t x_47; 
-x_43 = lean_ctor_get(x_42, 0);
-lean_inc(x_43);
-x_44 = lean_ctor_get(x_42, 1);
+lean_object* x_44; 
+x_44 = lean_ctor_get(x_43, 0);
 lean_inc(x_44);
-lean_dec(x_42);
-x_45 = lean_ctor_get(x_43, 0);
-lean_inc(x_45);
-x_46 = lean_ctor_get(x_43, 1);
-lean_inc(x_46);
-lean_dec(x_43);
-x_47 = l_List_isEmpty___rarg(x_45);
-if (x_47 == 0)
+if (lean_obj_tag(x_44) == 0)
 {
-lean_object* x_48; lean_object* x_49; lean_object* x_50; lean_object* x_51; 
-x_48 = lean_box(0);
-x_49 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_49, 0, x_46);
-lean_ctor_set(x_49, 1, x_48);
-x_50 = l_List_appendTR___rarg(x_45, x_49);
-x_51 = l_List_appendTR___rarg(x_50, x_13);
-x_1 = x_51;
+lean_object* x_45; lean_object* x_46; 
+x_45 = lean_ctor_get(x_43, 1);
+lean_inc(x_45);
+lean_dec(x_43);
+lean_inc(x_8);
+lean_inc(x_30);
+lean_inc(x_6);
+lean_inc(x_5);
+lean_inc(x_4);
+lean_inc(x_3);
+lean_inc(x_2);
+x_46 = l_Lean_Elab_Term_Do_ToCodeBlock_expandLiftMethod(x_12, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_45);
+if (lean_obj_tag(x_46) == 0)
+{
+lean_object* x_47; lean_object* x_48; lean_object* x_49; lean_object* x_50; uint8_t x_51; 
+x_47 = lean_ctor_get(x_46, 0);
+lean_inc(x_47);
+x_48 = lean_ctor_get(x_46, 1);
+lean_inc(x_48);
+lean_dec(x_46);
+x_49 = lean_ctor_get(x_47, 0);
+lean_inc(x_49);
+x_50 = lean_ctor_get(x_47, 1);
+lean_inc(x_50);
+lean_dec(x_47);
+x_51 = l_List_isEmpty___rarg(x_49);
+if (x_51 == 0)
+{
+lean_object* x_52; lean_object* x_53; lean_object* x_54; lean_object* x_55; 
+x_52 = lean_box(0);
+x_53 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_53, 0, x_50);
+lean_ctor_set(x_53, 1, x_52);
+x_54 = l_List_appendTR___rarg(x_49, x_53);
+x_55 = l_List_appendTR___rarg(x_54, x_13);
+x_1 = x_55;
 x_7 = x_30;
-x_9 = x_44;
+x_9 = x_48;
 goto _start;
 }
 else
 {
-lean_object* x_53; lean_object* x_54; uint8_t x_55; 
-lean_dec(x_45);
-lean_inc(x_46);
-x_53 = l_Lean_Syntax_getKind(x_46);
-x_54 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_liftMethodForbiddenBinder___closed__12;
-x_55 = lean_name_eq(x_53, x_54);
-if (x_55 == 0)
-{
-lean_object* x_56; uint8_t x_57; 
-x_56 = l_Lean_Elab_Term_Do_ToTerm_declToTerm___closed__2;
-x_57 = lean_name_eq(x_53, x_56);
-if (x_57 == 0)
-{
-lean_object* x_58; uint8_t x_59; 
-x_58 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_liftMethodForbiddenBinder___closed__6;
-x_59 = lean_name_eq(x_53, x_58);
+lean_object* x_57; lean_object* x_58; uint8_t x_59; 
+lean_dec(x_49);
+lean_inc(x_50);
+x_57 = l_Lean_Syntax_getKind(x_50);
+x_58 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_liftMethodForbiddenBinder___closed__12;
+x_59 = lean_name_eq(x_57, x_58);
 if (x_59 == 0)
 {
 lean_object* x_60; uint8_t x_61; 
-x_60 = l_Lean_Elab_Term_Do_ToTerm_reassignToTerm___closed__2;
-x_61 = lean_name_eq(x_53, x_60);
+x_60 = l_Lean_Elab_Term_Do_ToTerm_declToTerm___closed__2;
+x_61 = lean_name_eq(x_57, x_60);
 if (x_61 == 0)
 {
 lean_object* x_62; uint8_t x_63; 
-x_62 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_liftMethodForbiddenBinder___closed__14;
-x_63 = lean_name_eq(x_53, x_62);
+x_62 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_liftMethodForbiddenBinder___closed__6;
+x_63 = lean_name_eq(x_57, x_62);
 if (x_63 == 0)
 {
 lean_object* x_64; uint8_t x_65; 
-x_64 = l_Lean_Elab_Term_Do_isMutableLet___closed__2;
-x_65 = lean_name_eq(x_53, x_64);
+x_64 = l_Lean_Elab_Term_Do_ToTerm_reassignToTerm___closed__2;
+x_65 = lean_name_eq(x_57, x_64);
 if (x_65 == 0)
 {
 lean_object* x_66; uint8_t x_67; 
-x_66 = l_Lean_Elab_Term_Do_ToCodeBlock_checkLetArrowRHS___closed__6;
-x_67 = lean_name_eq(x_53, x_66);
+x_66 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_liftMethodForbiddenBinder___closed__14;
+x_67 = lean_name_eq(x_57, x_66);
 if (x_67 == 0)
 {
 lean_object* x_68; uint8_t x_69; 
-x_68 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___closed__2;
-x_69 = lean_name_eq(x_53, x_68);
+x_68 = l_Lean_Elab_Term_Do_isMutableLet___closed__2;
+x_69 = lean_name_eq(x_57, x_68);
 if (x_69 == 0)
 {
 lean_object* x_70; uint8_t x_71; 
-x_70 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__4;
-x_71 = lean_name_eq(x_53, x_70);
+x_70 = l_Lean_Elab_Term_Do_ToCodeBlock_checkLetArrowRHS___closed__6;
+x_71 = lean_name_eq(x_57, x_70);
 if (x_71 == 0)
 {
 lean_object* x_72; uint8_t x_73; 
-x_72 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__6;
-x_73 = lean_name_eq(x_53, x_72);
+x_72 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___closed__2;
+x_73 = lean_name_eq(x_57, x_72);
 if (x_73 == 0)
 {
 lean_object* x_74; uint8_t x_75; 
-x_74 = l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__5___lambda__2___closed__12;
-x_75 = lean_name_eq(x_53, x_74);
+x_74 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__4;
+x_75 = lean_name_eq(x_57, x_74);
 if (x_75 == 0)
 {
 lean_object* x_76; uint8_t x_77; 
-x_76 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__8;
-x_77 = lean_name_eq(x_53, x_76);
+x_76 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__6;
+x_77 = lean_name_eq(x_57, x_76);
 if (x_77 == 0)
 {
 lean_object* x_78; uint8_t x_79; 
-x_78 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__10;
-x_79 = lean_name_eq(x_53, x_78);
+x_78 = l_Array_forInUnsafe_loop___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___spec__5___lambda__2___closed__12;
+x_79 = lean_name_eq(x_57, x_78);
 if (x_79 == 0)
 {
 lean_object* x_80; uint8_t x_81; 
-x_80 = l_Lean_Elab_Term_Do_ToTerm_matchNestedTermResult___closed__14;
-x_81 = lean_name_eq(x_53, x_80);
+x_80 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__8;
+x_81 = lean_name_eq(x_57, x_80);
 if (x_81 == 0)
 {
 lean_object* x_82; uint8_t x_83; 
-x_82 = l_Lean_Elab_Term_Do_ToTerm_matchNestedTermResult___closed__18;
-x_83 = lean_name_eq(x_53, x_82);
+x_82 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__8;
+x_83 = lean_name_eq(x_57, x_82);
 if (x_83 == 0)
 {
 lean_object* x_84; uint8_t x_85; 
-x_84 = l_Lean_Elab_Term_Do_ToTerm_matchNestedTermResult___closed__20;
-x_85 = lean_name_eq(x_53, x_84);
+x_84 = l_Lean_Elab_Term_Do_ToTerm_matchNestedTermResult___closed__14;
+x_85 = lean_name_eq(x_57, x_84);
 if (x_85 == 0)
 {
 lean_object* x_86; uint8_t x_87; 
-x_86 = l_Lean_Elab_Term_Do_ToTerm_seqToTerm___closed__2;
-x_87 = lean_name_eq(x_53, x_86);
+x_86 = l_Lean_Elab_Term_Do_ToTerm_matchNestedTermResult___closed__18;
+x_87 = lean_name_eq(x_57, x_86);
 if (x_87 == 0)
 {
 lean_object* x_88; uint8_t x_89; 
-x_88 = l_Lean_Elab_Term_Do_ToTerm_seqToTerm___closed__4;
-x_89 = lean_name_eq(x_53, x_88);
+x_88 = l_Lean_Elab_Term_Do_ToTerm_matchNestedTermResult___closed__20;
+x_89 = lean_name_eq(x_57, x_88);
 if (x_89 == 0)
 {
 lean_object* x_90; uint8_t x_91; 
-x_90 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__12;
-x_91 = lean_name_eq(x_53, x_90);
+x_90 = l_Lean_Elab_Term_Do_ToTerm_seqToTerm___closed__2;
+x_91 = lean_name_eq(x_57, x_90);
 if (x_91 == 0)
 {
 lean_object* x_92; uint8_t x_93; 
-x_92 = l_Lean_Elab_Term_Do_mkAuxDeclFor___rarg___lambda__5___closed__7;
-x_93 = lean_name_eq(x_53, x_92);
+x_92 = l_Lean_Elab_Term_Do_ToTerm_seqToTerm___closed__4;
+x_93 = lean_name_eq(x_57, x_92);
 if (x_93 == 0)
 {
-lean_object* x_94; lean_object* x_95; lean_object* x_96; lean_object* x_97; lean_object* x_98; lean_object* x_99; lean_object* x_100; lean_object* x_101; lean_object* x_102; lean_object* x_103; 
+lean_object* x_94; uint8_t x_95; 
+x_94 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__10;
+x_95 = lean_name_eq(x_57, x_94);
+if (x_95 == 0)
+{
+lean_object* x_96; uint8_t x_97; 
+x_96 = l_Lean_Elab_Term_Do_mkAuxDeclFor___rarg___lambda__5___closed__7;
+x_97 = lean_name_eq(x_57, x_96);
+if (x_97 == 0)
+{
+lean_object* x_98; lean_object* x_99; lean_object* x_100; lean_object* x_101; lean_object* x_102; lean_object* x_103; lean_object* x_104; lean_object* x_105; lean_object* x_106; lean_object* x_107; 
 lean_dec(x_13);
-x_94 = l_Lean_MessageData_ofName(x_53);
-x_95 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__14;
-x_96 = lean_alloc_ctor(7, 2, 0);
-lean_ctor_set(x_96, 0, x_95);
-lean_ctor_set(x_96, 1, x_94);
-x_97 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__16;
-x_98 = lean_alloc_ctor(7, 2, 0);
-lean_ctor_set(x_98, 0, x_96);
-lean_ctor_set(x_98, 1, x_97);
-x_99 = l_Lean_MessageData_ofSyntax(x_46);
+x_98 = l_Lean_MessageData_ofName(x_57);
+x_99 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__12;
 x_100 = lean_alloc_ctor(7, 2, 0);
-lean_ctor_set(x_100, 0, x_98);
-lean_ctor_set(x_100, 1, x_99);
-x_101 = l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_Do_CodeBlocl_toMessageData_loop___spec__2___closed__6;
+lean_ctor_set(x_100, 0, x_99);
+lean_ctor_set(x_100, 1, x_98);
+x_101 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__14;
 x_102 = lean_alloc_ctor(7, 2, 0);
 lean_ctor_set(x_102, 0, x_100);
 lean_ctor_set(x_102, 1, x_101);
-x_103 = l_Lean_throwError___at_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___spec__3(x_102, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
+x_103 = l_Lean_MessageData_ofSyntax(x_50);
+x_104 = lean_alloc_ctor(7, 2, 0);
+lean_ctor_set(x_104, 0, x_102);
+lean_ctor_set(x_104, 1, x_103);
+x_105 = l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_Do_CodeBlocl_toMessageData_loop___spec__2___closed__6;
+x_106 = lean_alloc_ctor(7, 2, 0);
+lean_ctor_set(x_106, 0, x_104);
+lean_ctor_set(x_106, 1, x_105);
+x_107 = l_Lean_throwError___at_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___spec__3(x_106, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
 lean_dec(x_8);
 lean_dec(x_30);
 lean_dec(x_6);
@@ -33714,53 +34044,53 @@
 lean_dec(x_4);
 lean_dec(x_3);
 lean_dec(x_2);
-return x_103;
+return x_107;
 }
 else
 {
-lean_object* x_104; lean_object* x_105; uint8_t x_106; 
-lean_dec(x_53);
-x_104 = lean_unsigned_to_nat(0u);
-x_105 = l_Lean_Syntax_getArg(x_46, x_104);
-lean_dec(x_46);
-x_106 = l_List_isEmpty___rarg(x_13);
-if (x_106 == 0)
+lean_object* x_108; lean_object* x_109; uint8_t x_110; 
+lean_dec(x_57);
+x_108 = lean_unsigned_to_nat(0u);
+x_109 = l_Lean_Syntax_getArg(x_50, x_108);
+lean_dec(x_50);
+x_110 = l_List_isEmpty___rarg(x_13);
+if (x_110 == 0)
 {
-lean_object* x_107; 
-x_107 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode(x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
-if (lean_obj_tag(x_107) == 0)
+lean_object* x_111; 
+x_111 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode(x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
+if (lean_obj_tag(x_111) == 0)
 {
-lean_object* x_108; lean_object* x_109; lean_object* x_110; lean_object* x_111; 
-x_108 = lean_ctor_get(x_107, 0);
-lean_inc(x_108);
-x_109 = lean_ctor_get(x_107, 1);
-lean_inc(x_109);
-lean_dec(x_107);
-x_110 = l_Lean_Elab_Term_Do_mkSeq(x_105, x_108);
-lean_dec(x_108);
-x_111 = lean_alloc_ctor(0, 2, 0);
-lean_ctor_set(x_111, 0, x_110);
-lean_ctor_set(x_111, 1, x_109);
-return x_111;
-}
-else
-{
-lean_object* x_112; lean_object* x_113; lean_object* x_114; 
-lean_dec(x_105);
-x_112 = lean_ctor_get(x_107, 0);
+lean_object* x_112; lean_object* x_113; lean_object* x_114; lean_object* x_115; 
+x_112 = lean_ctor_get(x_111, 0);
 lean_inc(x_112);
-x_113 = lean_ctor_get(x_107, 1);
+x_113 = lean_ctor_get(x_111, 1);
 lean_inc(x_113);
-lean_dec(x_107);
-x_114 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_114, 0, x_112);
-lean_ctor_set(x_114, 1, x_113);
-return x_114;
+lean_dec(x_111);
+x_114 = l_Lean_Elab_Term_Do_mkSeq(x_109, x_112);
+lean_dec(x_112);
+x_115 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_115, 0, x_114);
+lean_ctor_set(x_115, 1, x_113);
+return x_115;
+}
+else
+{
+lean_object* x_116; lean_object* x_117; lean_object* x_118; 
+lean_dec(x_109);
+x_116 = lean_ctor_get(x_111, 0);
+lean_inc(x_116);
+x_117 = lean_ctor_get(x_111, 1);
+lean_inc(x_117);
+lean_dec(x_111);
+x_118 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_118, 0, x_116);
+lean_ctor_set(x_118, 1, x_117);
+return x_118;
 }
 }
 else
 {
-lean_object* x_115; lean_object* x_116; 
+lean_object* x_119; lean_object* x_120; 
 lean_dec(x_30);
 lean_dec(x_13);
 lean_dec(x_8);
@@ -33769,123 +34099,123 @@
 lean_dec(x_4);
 lean_dec(x_3);
 lean_dec(x_2);
-x_115 = l_Lean_Elab_Term_Do_mkTerminalAction(x_105);
-x_116 = lean_alloc_ctor(0, 2, 0);
-lean_ctor_set(x_116, 0, x_115);
-lean_ctor_set(x_116, 1, x_44);
-return x_116;
+x_119 = l_Lean_Elab_Term_Do_mkTerminalAction(x_109);
+x_120 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_120, 0, x_119);
+lean_ctor_set(x_120, 1, x_48);
+return x_120;
 }
 }
 }
 else
 {
-lean_object* x_117; lean_object* x_118; lean_object* x_119; 
-lean_dec(x_53);
-x_117 = l_Lean_Syntax_getArg(x_46, x_27);
-lean_dec(x_46);
-x_118 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems(x_117);
-x_119 = l_List_appendTR___rarg(x_118, x_13);
-x_1 = x_119;
+lean_object* x_121; lean_object* x_122; lean_object* x_123; 
+lean_dec(x_57);
+x_121 = l_Lean_Syntax_getArg(x_50, x_27);
+lean_dec(x_50);
+x_122 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems(x_121);
+x_123 = l_List_appendTR___rarg(x_122, x_13);
+x_1 = x_123;
 x_7 = x_30;
-x_9 = x_44;
+x_9 = x_48;
 goto _start;
 }
 }
 else
 {
-lean_object* x_121; 
-lean_dec(x_53);
-x_121 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode(x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
-if (lean_obj_tag(x_121) == 0)
+lean_object* x_125; 
+lean_dec(x_57);
+x_125 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode(x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
+if (lean_obj_tag(x_125) == 0)
 {
-lean_object* x_122; lean_object* x_123; lean_object* x_124; lean_object* x_125; 
-x_122 = lean_ctor_get(x_121, 0);
-lean_inc(x_122);
-x_123 = lean_ctor_get(x_121, 1);
-lean_inc(x_123);
-lean_dec(x_121);
-x_124 = l_Lean_Elab_Term_Do_mkSeq(x_46, x_122);
-lean_dec(x_122);
-x_125 = lean_alloc_ctor(0, 2, 0);
-lean_ctor_set(x_125, 0, x_124);
-lean_ctor_set(x_125, 1, x_123);
-return x_125;
-}
-else
-{
-lean_object* x_126; lean_object* x_127; lean_object* x_128; 
-lean_dec(x_46);
-x_126 = lean_ctor_get(x_121, 0);
+lean_object* x_126; lean_object* x_127; lean_object* x_128; lean_object* x_129; 
+x_126 = lean_ctor_get(x_125, 0);
 lean_inc(x_126);
-x_127 = lean_ctor_get(x_121, 1);
+x_127 = lean_ctor_get(x_125, 1);
 lean_inc(x_127);
-lean_dec(x_121);
-x_128 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_128, 0, x_126);
-lean_ctor_set(x_128, 1, x_127);
-return x_128;
-}
-}
+lean_dec(x_125);
+x_128 = l_Lean_Elab_Term_Do_mkSeq(x_50, x_126);
+lean_dec(x_126);
+x_129 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_129, 0, x_128);
+lean_ctor_set(x_129, 1, x_127);
+return x_129;
 }
 else
 {
-lean_object* x_129; 
-lean_dec(x_53);
-x_129 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode(x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
-if (lean_obj_tag(x_129) == 0)
-{
-lean_object* x_130; lean_object* x_131; lean_object* x_132; lean_object* x_133; 
-x_130 = lean_ctor_get(x_129, 0);
+lean_object* x_130; lean_object* x_131; lean_object* x_132; 
+lean_dec(x_50);
+x_130 = lean_ctor_get(x_125, 0);
 lean_inc(x_130);
-x_131 = lean_ctor_get(x_129, 1);
+x_131 = lean_ctor_get(x_125, 1);
 lean_inc(x_131);
-lean_dec(x_129);
-x_132 = l_Lean_Elab_Term_Do_mkSeq(x_46, x_130);
-lean_dec(x_130);
-x_133 = lean_alloc_ctor(0, 2, 0);
-lean_ctor_set(x_133, 0, x_132);
-lean_ctor_set(x_133, 1, x_131);
-return x_133;
+lean_dec(x_125);
+x_132 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_132, 0, x_130);
+lean_ctor_set(x_132, 1, x_131);
+return x_132;
+}
+}
 }
 else
 {
-lean_object* x_134; lean_object* x_135; lean_object* x_136; 
-lean_dec(x_46);
-x_134 = lean_ctor_get(x_129, 0);
+lean_object* x_133; 
+lean_dec(x_57);
+x_133 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode(x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
+if (lean_obj_tag(x_133) == 0)
+{
+lean_object* x_134; lean_object* x_135; lean_object* x_136; lean_object* x_137; 
+x_134 = lean_ctor_get(x_133, 0);
 lean_inc(x_134);
-x_135 = lean_ctor_get(x_129, 1);
+x_135 = lean_ctor_get(x_133, 1);
 lean_inc(x_135);
-lean_dec(x_129);
-x_136 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_136, 0, x_134);
-lean_ctor_set(x_136, 1, x_135);
-return x_136;
-}
-}
-}
-else
-{
-lean_object* x_137; 
-lean_dec(x_53);
-x_137 = l_Lean_Elab_Term_Do_ToCodeBlock_doReturnToCode(x_46, x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
-lean_dec(x_30);
-lean_dec(x_13);
-lean_dec(x_46);
+lean_dec(x_133);
+x_136 = l_Lean_Elab_Term_Do_mkSeq(x_50, x_134);
+lean_dec(x_134);
+x_137 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_137, 0, x_136);
+lean_ctor_set(x_137, 1, x_135);
 return x_137;
 }
-}
 else
 {
-lean_object* x_138; 
-lean_dec(x_53);
-x_138 = l_Lean_Elab_Term_Do_ToCodeBlock_ensureInsideFor(x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
-if (lean_obj_tag(x_138) == 0)
-{
-lean_object* x_139; lean_object* x_140; 
-x_139 = lean_ctor_get(x_138, 1);
+lean_object* x_138; lean_object* x_139; lean_object* x_140; 
+lean_dec(x_50);
+x_138 = lean_ctor_get(x_133, 0);
+lean_inc(x_138);
+x_139 = lean_ctor_get(x_133, 1);
 lean_inc(x_139);
-lean_dec(x_138);
-x_140 = l_Lean_Elab_Term_Do_ToCodeBlock_ensureEOS(x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_139);
+lean_dec(x_133);
+x_140 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_140, 0, x_138);
+lean_ctor_set(x_140, 1, x_139);
+return x_140;
+}
+}
+}
+else
+{
+lean_object* x_141; 
+lean_dec(x_57);
+x_141 = l_Lean_Elab_Term_Do_ToCodeBlock_doReturnToCode(x_50, x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
+lean_dec(x_30);
+lean_dec(x_13);
+lean_dec(x_50);
+return x_141;
+}
+}
+else
+{
+lean_object* x_142; 
+lean_dec(x_57);
+x_142 = l_Lean_Elab_Term_Do_ToCodeBlock_ensureInsideFor(x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
+if (lean_obj_tag(x_142) == 0)
+{
+lean_object* x_143; lean_object* x_144; 
+x_143 = lean_ctor_get(x_142, 1);
+lean_inc(x_143);
+lean_dec(x_142);
+x_144 = l_Lean_Elab_Term_Do_ToCodeBlock_ensureEOS(x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_143);
 lean_dec(x_8);
 lean_dec(x_30);
 lean_dec(x_6);
@@ -33894,69 +34224,69 @@
 lean_dec(x_3);
 lean_dec(x_2);
 lean_dec(x_13);
-if (lean_obj_tag(x_140) == 0)
+if (lean_obj_tag(x_144) == 0)
 {
-lean_object* x_141; lean_object* x_142; lean_object* x_143; 
-x_141 = lean_ctor_get(x_140, 1);
-lean_inc(x_141);
-lean_dec(x_140);
-x_142 = l_Lean_Elab_Term_Do_mkContinue(x_46);
-x_143 = lean_alloc_ctor(0, 2, 0);
-lean_ctor_set(x_143, 0, x_142);
-lean_ctor_set(x_143, 1, x_141);
-return x_143;
-}
-else
-{
-lean_object* x_144; lean_object* x_145; lean_object* x_146; 
-lean_dec(x_46);
-x_144 = lean_ctor_get(x_140, 0);
-lean_inc(x_144);
-x_145 = lean_ctor_get(x_140, 1);
+lean_object* x_145; lean_object* x_146; lean_object* x_147; 
+x_145 = lean_ctor_get(x_144, 1);
 lean_inc(x_145);
-lean_dec(x_140);
-x_146 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_146, 0, x_144);
-lean_ctor_set(x_146, 1, x_145);
-return x_146;
-}
+lean_dec(x_144);
+x_146 = l_Lean_Elab_Term_Do_mkContinue(x_50);
+x_147 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_147, 0, x_146);
+lean_ctor_set(x_147, 1, x_145);
+return x_147;
 }
 else
 {
-lean_object* x_147; lean_object* x_148; lean_object* x_149; 
-lean_dec(x_46);
-lean_dec(x_30);
-lean_dec(x_13);
-lean_dec(x_8);
-lean_dec(x_6);
-lean_dec(x_5);
-lean_dec(x_4);
-lean_dec(x_3);
-lean_dec(x_2);
-x_147 = lean_ctor_get(x_138, 0);
-lean_inc(x_147);
-x_148 = lean_ctor_get(x_138, 1);
+lean_object* x_148; lean_object* x_149; lean_object* x_150; 
+lean_dec(x_50);
+x_148 = lean_ctor_get(x_144, 0);
 lean_inc(x_148);
-lean_dec(x_138);
-x_149 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_149, 0, x_147);
-lean_ctor_set(x_149, 1, x_148);
-return x_149;
-}
+x_149 = lean_ctor_get(x_144, 1);
+lean_inc(x_149);
+lean_dec(x_144);
+x_150 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_150, 0, x_148);
+lean_ctor_set(x_150, 1, x_149);
+return x_150;
 }
 }
 else
 {
-lean_object* x_150; 
-lean_dec(x_53);
-x_150 = l_Lean_Elab_Term_Do_ToCodeBlock_ensureInsideFor(x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
-if (lean_obj_tag(x_150) == 0)
-{
-lean_object* x_151; lean_object* x_152; 
-x_151 = lean_ctor_get(x_150, 1);
+lean_object* x_151; lean_object* x_152; lean_object* x_153; 
+lean_dec(x_50);
+lean_dec(x_30);
+lean_dec(x_13);
+lean_dec(x_8);
+lean_dec(x_6);
+lean_dec(x_5);
+lean_dec(x_4);
+lean_dec(x_3);
+lean_dec(x_2);
+x_151 = lean_ctor_get(x_142, 0);
 lean_inc(x_151);
-lean_dec(x_150);
-x_152 = l_Lean_Elab_Term_Do_ToCodeBlock_ensureEOS(x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_151);
+x_152 = lean_ctor_get(x_142, 1);
+lean_inc(x_152);
+lean_dec(x_142);
+x_153 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_153, 0, x_151);
+lean_ctor_set(x_153, 1, x_152);
+return x_153;
+}
+}
+}
+else
+{
+lean_object* x_154; 
+lean_dec(x_57);
+x_154 = l_Lean_Elab_Term_Do_ToCodeBlock_ensureInsideFor(x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
+if (lean_obj_tag(x_154) == 0)
+{
+lean_object* x_155; lean_object* x_156; 
+x_155 = lean_ctor_get(x_154, 1);
+lean_inc(x_155);
+lean_dec(x_154);
+x_156 = l_Lean_Elab_Term_Do_ToCodeBlock_ensureEOS(x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_155);
 lean_dec(x_8);
 lean_dec(x_30);
 lean_dec(x_6);
@@ -33965,551 +34295,528 @@
 lean_dec(x_3);
 lean_dec(x_2);
 lean_dec(x_13);
-if (lean_obj_tag(x_152) == 0)
+if (lean_obj_tag(x_156) == 0)
 {
-lean_object* x_153; lean_object* x_154; lean_object* x_155; 
-x_153 = lean_ctor_get(x_152, 1);
-lean_inc(x_153);
-lean_dec(x_152);
-x_154 = l_Lean_Elab_Term_Do_mkBreak(x_46);
-x_155 = lean_alloc_ctor(0, 2, 0);
-lean_ctor_set(x_155, 0, x_154);
-lean_ctor_set(x_155, 1, x_153);
-return x_155;
-}
-else
-{
-lean_object* x_156; lean_object* x_157; lean_object* x_158; 
-lean_dec(x_46);
-x_156 = lean_ctor_get(x_152, 0);
-lean_inc(x_156);
-x_157 = lean_ctor_get(x_152, 1);
+lean_object* x_157; lean_object* x_158; lean_object* x_159; 
+x_157 = lean_ctor_get(x_156, 1);
 lean_inc(x_157);
-lean_dec(x_152);
-x_158 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_158, 0, x_156);
-lean_ctor_set(x_158, 1, x_157);
-return x_158;
-}
+lean_dec(x_156);
+x_158 = l_Lean_Elab_Term_Do_mkBreak(x_50);
+x_159 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_159, 0, x_158);
+lean_ctor_set(x_159, 1, x_157);
+return x_159;
 }
 else
 {
-lean_object* x_159; lean_object* x_160; lean_object* x_161; 
-lean_dec(x_46);
-lean_dec(x_30);
-lean_dec(x_13);
-lean_dec(x_8);
-lean_dec(x_6);
-lean_dec(x_5);
-lean_dec(x_4);
-lean_dec(x_3);
-lean_dec(x_2);
-x_159 = lean_ctor_get(x_150, 0);
-lean_inc(x_159);
-x_160 = lean_ctor_get(x_150, 1);
+lean_object* x_160; lean_object* x_161; lean_object* x_162; 
+lean_dec(x_50);
+x_160 = lean_ctor_get(x_156, 0);
 lean_inc(x_160);
-lean_dec(x_150);
-x_161 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_161, 0, x_159);
-lean_ctor_set(x_161, 1, x_160);
-return x_161;
-}
-}
-}
-else
-{
-lean_object* x_162; 
-lean_dec(x_53);
-x_162 = l_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode(x_46, x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
+x_161 = lean_ctor_get(x_156, 1);
+lean_inc(x_161);
+lean_dec(x_156);
+x_162 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_162, 0, x_160);
+lean_ctor_set(x_162, 1, x_161);
 return x_162;
 }
 }
 else
 {
-lean_object* x_163; 
-lean_dec(x_53);
-x_163 = l_Lean_Elab_Term_Do_ToCodeBlock_doMatchExprToCode(x_46, x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
-return x_163;
+lean_object* x_163; lean_object* x_164; lean_object* x_165; 
+lean_dec(x_50);
+lean_dec(x_30);
+lean_dec(x_13);
+lean_dec(x_8);
+lean_dec(x_6);
+lean_dec(x_5);
+lean_dec(x_4);
+lean_dec(x_3);
+lean_dec(x_2);
+x_163 = lean_ctor_get(x_154, 0);
+lean_inc(x_163);
+x_164 = lean_ctor_get(x_154, 1);
+lean_inc(x_164);
+lean_dec(x_154);
+x_165 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_165, 0, x_163);
+lean_ctor_set(x_165, 1, x_164);
+return x_165;
+}
 }
 }
 else
 {
-lean_object* x_164; 
-lean_dec(x_53);
-x_164 = l_Lean_Elab_Term_Do_ToCodeBlock_doMatchToCode(x_46, x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
-return x_164;
-}
-}
-else
-{
-lean_object* x_165; lean_object* x_166; 
-lean_dec(x_53);
-x_165 = lean_alloc_closure((void*)(l_Lean_Elab_Term_Do_ToCodeBlock_doForToCode), 10, 7);
-lean_closure_set(x_165, 0, x_46);
-lean_closure_set(x_165, 1, x_13);
-lean_closure_set(x_165, 2, x_2);
-lean_closure_set(x_165, 3, x_3);
-lean_closure_set(x_165, 4, x_4);
-lean_closure_set(x_165, 5, x_5);
-lean_closure_set(x_165, 6, x_6);
-x_166 = l_Lean_Core_withFreshMacroScope___rarg(x_165, x_30, x_8, x_44);
+lean_object* x_166; 
+lean_dec(x_57);
+x_166 = l_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode(x_50, x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
 return x_166;
 }
 }
 else
 {
 lean_object* x_167; 
-lean_dec(x_53);
-x_167 = l_Lean_Elab_Term_Do_ToCodeBlock_doUnlessToCode(x_46, x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
+lean_dec(x_57);
+x_167 = l_Lean_Elab_Term_Do_ToCodeBlock_doMatchExprToCode(x_50, x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
 return x_167;
 }
 }
 else
 {
 lean_object* x_168; 
-lean_dec(x_53);
-x_168 = l_Lean_Elab_Term_Do_ToCodeBlock_doIfToCode(x_46, x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
+lean_dec(x_57);
+x_168 = l_Lean_Elab_Term_Do_ToCodeBlock_doMatchToCode(x_50, x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
 return x_168;
 }
 }
 else
 {
-lean_object* x_169; 
-lean_dec(x_53);
-x_169 = l_Lean_Elab_Term_Do_ToCodeBlock_doReassignArrowToCode(x_46, x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
-return x_169;
-}
-}
-else
-{
-lean_object* x_170; 
-lean_dec(x_53);
-x_170 = l_Lean_Elab_Term_Do_ToCodeBlock_doLetElseToCode(x_46, x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
+lean_object* x_169; lean_object* x_170; 
+lean_dec(x_57);
+x_169 = lean_alloc_closure((void*)(l_Lean_Elab_Term_Do_ToCodeBlock_doForToCode), 10, 7);
+lean_closure_set(x_169, 0, x_50);
+lean_closure_set(x_169, 1, x_13);
+lean_closure_set(x_169, 2, x_2);
+lean_closure_set(x_169, 3, x_3);
+lean_closure_set(x_169, 4, x_4);
+lean_closure_set(x_169, 5, x_5);
+lean_closure_set(x_169, 6, x_6);
+x_170 = l_Lean_Core_withFreshMacroScope___rarg(x_169, x_30, x_8, x_48);
 return x_170;
 }
 }
 else
 {
 lean_object* x_171; 
-lean_dec(x_53);
-x_171 = l_Lean_Elab_Term_Do_ToCodeBlock_doLetArrowToCode(x_46, x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
+lean_dec(x_57);
+x_171 = l_Lean_Elab_Term_Do_ToCodeBlock_doUnlessToCode(x_50, x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
 return x_171;
 }
 }
 else
 {
 lean_object* x_172; 
-lean_dec(x_53);
+lean_dec(x_57);
+x_172 = l_Lean_Elab_Term_Do_ToCodeBlock_doIfToCode(x_50, x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
+return x_172;
+}
+}
+else
+{
+lean_object* x_173; 
+lean_dec(x_57);
+x_173 = l_Lean_Elab_Term_Do_ToCodeBlock_doReassignArrowToCode(x_50, x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
+return x_173;
+}
+}
+else
+{
+lean_object* x_174; 
+lean_dec(x_57);
+x_174 = l_Lean_Elab_Term_Do_ToCodeBlock_doLetElseToCode(x_50, x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
+return x_174;
+}
+}
+else
+{
+lean_object* x_175; 
+lean_dec(x_57);
+x_175 = l_Lean_Elab_Term_Do_ToCodeBlock_doLetArrowToCode(x_50, x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
+return x_175;
+}
+}
+else
+{
+lean_object* x_176; 
+lean_dec(x_57);
 lean_inc(x_8);
 lean_inc(x_30);
 lean_inc(x_6);
 lean_inc(x_5);
 lean_inc(x_4);
 lean_inc(x_3);
-x_172 = l_Lean_Elab_Term_Do_getDoReassignVars(x_46, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
-if (lean_obj_tag(x_172) == 0)
+x_176 = l_Lean_Elab_Term_Do_getDoReassignVars(x_50, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
+if (lean_obj_tag(x_176) == 0)
 {
-lean_object* x_173; lean_object* x_174; lean_object* x_175; 
-x_173 = lean_ctor_get(x_172, 0);
-lean_inc(x_173);
-x_174 = lean_ctor_get(x_172, 1);
-lean_inc(x_174);
-lean_dec(x_172);
-x_175 = l_Lean_Elab_Term_Do_ToCodeBlock_checkReassignable(x_173, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_174);
-if (lean_obj_tag(x_175) == 0)
-{
-lean_object* x_176; lean_object* x_177; 
-x_176 = lean_ctor_get(x_175, 1);
-lean_inc(x_176);
-lean_dec(x_175);
-lean_inc(x_8);
-lean_inc(x_30);
-lean_inc(x_6);
-lean_inc(x_5);
-lean_inc(x_4);
-lean_inc(x_3);
-x_177 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode(x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_176);
-if (lean_obj_tag(x_177) == 0)
-{
-lean_object* x_178; lean_object* x_179; lean_object* x_180; 
-x_178 = lean_ctor_get(x_177, 0);
+lean_object* x_177; lean_object* x_178; lean_object* x_179; 
+x_177 = lean_ctor_get(x_176, 0);
+lean_inc(x_177);
+x_178 = lean_ctor_get(x_176, 1);
 lean_inc(x_178);
-x_179 = lean_ctor_get(x_177, 1);
-lean_inc(x_179);
-lean_dec(x_177);
-x_180 = l_Lean_Elab_Term_Do_mkReassignCore(x_173, x_46, x_178, x_3, x_4, x_5, x_6, x_30, x_8, x_179);
-return x_180;
-}
-else
+lean_dec(x_176);
+x_179 = l_Lean_Elab_Term_Do_ToCodeBlock_checkReassignable(x_177, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_178);
+if (lean_obj_tag(x_179) == 0)
 {
-lean_object* x_181; lean_object* x_182; lean_object* x_183; 
-lean_dec(x_173);
-lean_dec(x_46);
-lean_dec(x_30);
-lean_dec(x_8);
-lean_dec(x_6);
-lean_dec(x_5);
-lean_dec(x_4);
-lean_dec(x_3);
-x_181 = lean_ctor_get(x_177, 0);
-lean_inc(x_181);
-x_182 = lean_ctor_get(x_177, 1);
-lean_inc(x_182);
-lean_dec(x_177);
-x_183 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_183, 0, x_181);
-lean_ctor_set(x_183, 1, x_182);
-return x_183;
-}
-}
-else
-{
-lean_object* x_184; lean_object* x_185; lean_object* x_186; 
-lean_dec(x_173);
-lean_dec(x_46);
-lean_dec(x_30);
-lean_dec(x_13);
-lean_dec(x_8);
-lean_dec(x_6);
-lean_dec(x_5);
-lean_dec(x_4);
-lean_dec(x_3);
-lean_dec(x_2);
-x_184 = lean_ctor_get(x_175, 0);
-lean_inc(x_184);
-x_185 = lean_ctor_get(x_175, 1);
-lean_inc(x_185);
-lean_dec(x_175);
-x_186 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_186, 0, x_184);
-lean_ctor_set(x_186, 1, x_185);
-return x_186;
-}
-}
-else
-{
-lean_object* x_187; lean_object* x_188; lean_object* x_189; 
-lean_dec(x_46);
-lean_dec(x_30);
-lean_dec(x_13);
-lean_dec(x_8);
-lean_dec(x_6);
-lean_dec(x_5);
-lean_dec(x_4);
-lean_dec(x_3);
-lean_dec(x_2);
-x_187 = lean_ctor_get(x_172, 0);
-lean_inc(x_187);
-x_188 = lean_ctor_get(x_172, 1);
-lean_inc(x_188);
-lean_dec(x_172);
-x_189 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_189, 0, x_187);
-lean_ctor_set(x_189, 1, x_188);
-return x_189;
-}
-}
-}
-else
-{
-lean_object* x_190; 
-lean_dec(x_53);
+lean_object* x_180; lean_object* x_181; 
+x_180 = lean_ctor_get(x_179, 1);
+lean_inc(x_180);
+lean_dec(x_179);
 lean_inc(x_8);
 lean_inc(x_30);
 lean_inc(x_6);
 lean_inc(x_5);
 lean_inc(x_4);
 lean_inc(x_3);
-x_190 = l_Lean_Elab_Term_Do_getDoLetRecVars(x_46, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
-if (lean_obj_tag(x_190) == 0)
+x_181 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode(x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_180);
+if (lean_obj_tag(x_181) == 0)
+{
+lean_object* x_182; lean_object* x_183; lean_object* x_184; 
+x_182 = lean_ctor_get(x_181, 0);
+lean_inc(x_182);
+x_183 = lean_ctor_get(x_181, 1);
+lean_inc(x_183);
+lean_dec(x_181);
+x_184 = l_Lean_Elab_Term_Do_mkReassignCore(x_177, x_50, x_182, x_3, x_4, x_5, x_6, x_30, x_8, x_183);
+return x_184;
+}
+else
+{
+lean_object* x_185; lean_object* x_186; lean_object* x_187; 
+lean_dec(x_177);
+lean_dec(x_50);
+lean_dec(x_30);
+lean_dec(x_8);
+lean_dec(x_6);
+lean_dec(x_5);
+lean_dec(x_4);
+lean_dec(x_3);
+x_185 = lean_ctor_get(x_181, 0);
+lean_inc(x_185);
+x_186 = lean_ctor_get(x_181, 1);
+lean_inc(x_186);
+lean_dec(x_181);
+x_187 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_187, 0, x_185);
+lean_ctor_set(x_187, 1, x_186);
+return x_187;
+}
+}
+else
+{
+lean_object* x_188; lean_object* x_189; lean_object* x_190; 
+lean_dec(x_177);
+lean_dec(x_50);
+lean_dec(x_30);
+lean_dec(x_13);
+lean_dec(x_8);
+lean_dec(x_6);
+lean_dec(x_5);
+lean_dec(x_4);
+lean_dec(x_3);
+lean_dec(x_2);
+x_188 = lean_ctor_get(x_179, 0);
+lean_inc(x_188);
+x_189 = lean_ctor_get(x_179, 1);
+lean_inc(x_189);
+lean_dec(x_179);
+x_190 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_190, 0, x_188);
+lean_ctor_set(x_190, 1, x_189);
+return x_190;
+}
+}
+else
 {
 lean_object* x_191; lean_object* x_192; lean_object* x_193; 
-x_191 = lean_ctor_get(x_190, 0);
+lean_dec(x_50);
+lean_dec(x_30);
+lean_dec(x_13);
+lean_dec(x_8);
+lean_dec(x_6);
+lean_dec(x_5);
+lean_dec(x_4);
+lean_dec(x_3);
+lean_dec(x_2);
+x_191 = lean_ctor_get(x_176, 0);
 lean_inc(x_191);
-x_192 = lean_ctor_get(x_190, 1);
+x_192 = lean_ctor_get(x_176, 1);
 lean_inc(x_192);
-lean_dec(x_190);
-x_193 = l_Lean_Elab_Term_Do_ToCodeBlock_checkNotShadowingMutable(x_191, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_192);
-if (lean_obj_tag(x_193) == 0)
-{
-lean_object* x_194; lean_object* x_195; 
-x_194 = lean_ctor_get(x_193, 1);
-lean_inc(x_194);
-lean_dec(x_193);
-x_195 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode(x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_194);
-if (lean_obj_tag(x_195) == 0)
-{
-lean_object* x_196; lean_object* x_197; lean_object* x_198; lean_object* x_199; 
-x_196 = lean_ctor_get(x_195, 0);
-lean_inc(x_196);
-x_197 = lean_ctor_get(x_195, 1);
-lean_inc(x_197);
-lean_dec(x_195);
-x_198 = l_Lean_Elab_Term_Do_mkVarDeclCore(x_191, x_46, x_196);
-x_199 = lean_alloc_ctor(0, 2, 0);
-lean_ctor_set(x_199, 0, x_198);
-lean_ctor_set(x_199, 1, x_197);
-return x_199;
-}
-else
-{
-lean_object* x_200; lean_object* x_201; lean_object* x_202; 
-lean_dec(x_191);
-lean_dec(x_46);
-x_200 = lean_ctor_get(x_195, 0);
-lean_inc(x_200);
-x_201 = lean_ctor_get(x_195, 1);
-lean_inc(x_201);
-lean_dec(x_195);
-x_202 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_202, 0, x_200);
-lean_ctor_set(x_202, 1, x_201);
-return x_202;
-}
-}
-else
-{
-lean_object* x_203; lean_object* x_204; lean_object* x_205; 
-lean_dec(x_191);
-lean_dec(x_46);
-lean_dec(x_30);
-lean_dec(x_13);
-lean_dec(x_8);
-lean_dec(x_6);
-lean_dec(x_5);
-lean_dec(x_4);
-lean_dec(x_3);
-lean_dec(x_2);
-x_203 = lean_ctor_get(x_193, 0);
-lean_inc(x_203);
-x_204 = lean_ctor_get(x_193, 1);
-lean_inc(x_204);
-lean_dec(x_193);
-x_205 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_205, 0, x_203);
-lean_ctor_set(x_205, 1, x_204);
-return x_205;
-}
-}
-else
-{
-lean_object* x_206; lean_object* x_207; lean_object* x_208; 
-lean_dec(x_46);
-lean_dec(x_30);
-lean_dec(x_13);
-lean_dec(x_8);
-lean_dec(x_6);
-lean_dec(x_5);
-lean_dec(x_4);
-lean_dec(x_3);
-lean_dec(x_2);
-x_206 = lean_ctor_get(x_190, 0);
-lean_inc(x_206);
-x_207 = lean_ctor_get(x_190, 1);
-lean_inc(x_207);
-lean_dec(x_190);
-x_208 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_208, 0, x_206);
-lean_ctor_set(x_208, 1, x_207);
-return x_208;
+lean_dec(x_176);
+x_193 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_193, 0, x_191);
+lean_ctor_set(x_193, 1, x_192);
+return x_193;
 }
 }
 }
 else
 {
-lean_object* x_209; 
-lean_dec(x_53);
+lean_object* x_194; 
+lean_dec(x_57);
 lean_inc(x_8);
 lean_inc(x_30);
 lean_inc(x_6);
 lean_inc(x_5);
 lean_inc(x_4);
 lean_inc(x_3);
-x_209 = l_Lean_Elab_Term_Do_getDoHaveVars(x_46, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
-if (lean_obj_tag(x_209) == 0)
+x_194 = l_Lean_Elab_Term_Do_getDoLetRecVars(x_50, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
+if (lean_obj_tag(x_194) == 0)
+{
+lean_object* x_195; lean_object* x_196; lean_object* x_197; 
+x_195 = lean_ctor_get(x_194, 0);
+lean_inc(x_195);
+x_196 = lean_ctor_get(x_194, 1);
+lean_inc(x_196);
+lean_dec(x_194);
+x_197 = l_Lean_Elab_Term_Do_ToCodeBlock_checkNotShadowingMutable(x_195, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_196);
+if (lean_obj_tag(x_197) == 0)
+{
+lean_object* x_198; lean_object* x_199; 
+x_198 = lean_ctor_get(x_197, 1);
+lean_inc(x_198);
+lean_dec(x_197);
+x_199 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode(x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_198);
+if (lean_obj_tag(x_199) == 0)
+{
+lean_object* x_200; lean_object* x_201; lean_object* x_202; lean_object* x_203; 
+x_200 = lean_ctor_get(x_199, 0);
+lean_inc(x_200);
+x_201 = lean_ctor_get(x_199, 1);
+lean_inc(x_201);
+lean_dec(x_199);
+x_202 = l_Lean_Elab_Term_Do_mkVarDeclCore(x_195, x_50, x_200);
+x_203 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_203, 0, x_202);
+lean_ctor_set(x_203, 1, x_201);
+return x_203;
+}
+else
+{
+lean_object* x_204; lean_object* x_205; lean_object* x_206; 
+lean_dec(x_195);
+lean_dec(x_50);
+x_204 = lean_ctor_get(x_199, 0);
+lean_inc(x_204);
+x_205 = lean_ctor_get(x_199, 1);
+lean_inc(x_205);
+lean_dec(x_199);
+x_206 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_206, 0, x_204);
+lean_ctor_set(x_206, 1, x_205);
+return x_206;
+}
+}
+else
+{
+lean_object* x_207; lean_object* x_208; lean_object* x_209; 
+lean_dec(x_195);
+lean_dec(x_50);
+lean_dec(x_30);
+lean_dec(x_13);
+lean_dec(x_8);
+lean_dec(x_6);
+lean_dec(x_5);
+lean_dec(x_4);
+lean_dec(x_3);
+lean_dec(x_2);
+x_207 = lean_ctor_get(x_197, 0);
+lean_inc(x_207);
+x_208 = lean_ctor_get(x_197, 1);
+lean_inc(x_208);
+lean_dec(x_197);
+x_209 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_209, 0, x_207);
+lean_ctor_set(x_209, 1, x_208);
+return x_209;
+}
+}
+else
 {
 lean_object* x_210; lean_object* x_211; lean_object* x_212; 
-x_210 = lean_ctor_get(x_209, 0);
+lean_dec(x_50);
+lean_dec(x_30);
+lean_dec(x_13);
+lean_dec(x_8);
+lean_dec(x_6);
+lean_dec(x_5);
+lean_dec(x_4);
+lean_dec(x_3);
+lean_dec(x_2);
+x_210 = lean_ctor_get(x_194, 0);
 lean_inc(x_210);
-x_211 = lean_ctor_get(x_209, 1);
+x_211 = lean_ctor_get(x_194, 1);
 lean_inc(x_211);
-lean_dec(x_209);
-x_212 = l_Lean_Elab_Term_Do_ToCodeBlock_checkNotShadowingMutable(x_210, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_211);
-if (lean_obj_tag(x_212) == 0)
-{
-lean_object* x_213; lean_object* x_214; 
-x_213 = lean_ctor_get(x_212, 1);
-lean_inc(x_213);
-lean_dec(x_212);
-x_214 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode(x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_213);
-if (lean_obj_tag(x_214) == 0)
-{
-lean_object* x_215; lean_object* x_216; lean_object* x_217; lean_object* x_218; 
-x_215 = lean_ctor_get(x_214, 0);
-lean_inc(x_215);
-x_216 = lean_ctor_get(x_214, 1);
-lean_inc(x_216);
-lean_dec(x_214);
-x_217 = l_Lean_Elab_Term_Do_mkVarDeclCore(x_210, x_46, x_215);
-x_218 = lean_alloc_ctor(0, 2, 0);
-lean_ctor_set(x_218, 0, x_217);
-lean_ctor_set(x_218, 1, x_216);
-return x_218;
-}
-else
-{
-lean_object* x_219; lean_object* x_220; lean_object* x_221; 
-lean_dec(x_210);
-lean_dec(x_46);
-x_219 = lean_ctor_get(x_214, 0);
-lean_inc(x_219);
-x_220 = lean_ctor_get(x_214, 1);
-lean_inc(x_220);
-lean_dec(x_214);
-x_221 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_221, 0, x_219);
-lean_ctor_set(x_221, 1, x_220);
-return x_221;
-}
-}
-else
-{
-lean_object* x_222; lean_object* x_223; lean_object* x_224; 
-lean_dec(x_210);
-lean_dec(x_46);
-lean_dec(x_30);
-lean_dec(x_13);
-lean_dec(x_8);
-lean_dec(x_6);
-lean_dec(x_5);
-lean_dec(x_4);
-lean_dec(x_3);
-lean_dec(x_2);
-x_222 = lean_ctor_get(x_212, 0);
-lean_inc(x_222);
-x_223 = lean_ctor_get(x_212, 1);
-lean_inc(x_223);
-lean_dec(x_212);
-x_224 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_224, 0, x_222);
-lean_ctor_set(x_224, 1, x_223);
-return x_224;
-}
-}
-else
-{
-lean_object* x_225; lean_object* x_226; lean_object* x_227; 
-lean_dec(x_46);
-lean_dec(x_30);
-lean_dec(x_13);
-lean_dec(x_8);
-lean_dec(x_6);
-lean_dec(x_5);
-lean_dec(x_4);
-lean_dec(x_3);
-lean_dec(x_2);
-x_225 = lean_ctor_get(x_209, 0);
-lean_inc(x_225);
-x_226 = lean_ctor_get(x_209, 1);
-lean_inc(x_226);
-lean_dec(x_209);
-x_227 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_227, 0, x_225);
-lean_ctor_set(x_227, 1, x_226);
-return x_227;
+lean_dec(x_194);
+x_212 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_212, 0, x_210);
+lean_ctor_set(x_212, 1, x_211);
+return x_212;
 }
 }
 }
 else
 {
-lean_object* x_228; 
-lean_dec(x_53);
+lean_object* x_213; 
+lean_dec(x_57);
 lean_inc(x_8);
 lean_inc(x_30);
 lean_inc(x_6);
 lean_inc(x_5);
 lean_inc(x_4);
 lean_inc(x_3);
-x_228 = l_Lean_Elab_Term_Do_getDoLetVars(x_46, x_3, x_4, x_5, x_6, x_30, x_8, x_44);
-if (lean_obj_tag(x_228) == 0)
+x_213 = l_Lean_Elab_Term_Do_getDoHaveVars(x_50, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
+if (lean_obj_tag(x_213) == 0)
+{
+lean_object* x_214; lean_object* x_215; lean_object* x_216; 
+x_214 = lean_ctor_get(x_213, 0);
+lean_inc(x_214);
+x_215 = lean_ctor_get(x_213, 1);
+lean_inc(x_215);
+lean_dec(x_213);
+x_216 = l_Lean_Elab_Term_Do_ToCodeBlock_checkNotShadowingMutable(x_214, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_215);
+if (lean_obj_tag(x_216) == 0)
+{
+lean_object* x_217; lean_object* x_218; 
+x_217 = lean_ctor_get(x_216, 1);
+lean_inc(x_217);
+lean_dec(x_216);
+x_218 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode(x_13, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_217);
+if (lean_obj_tag(x_218) == 0)
+{
+lean_object* x_219; lean_object* x_220; lean_object* x_221; lean_object* x_222; 
+x_219 = lean_ctor_get(x_218, 0);
+lean_inc(x_219);
+x_220 = lean_ctor_get(x_218, 1);
+lean_inc(x_220);
+lean_dec(x_218);
+x_221 = l_Lean_Elab_Term_Do_mkVarDeclCore(x_214, x_50, x_219);
+x_222 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_222, 0, x_221);
+lean_ctor_set(x_222, 1, x_220);
+return x_222;
+}
+else
+{
+lean_object* x_223; lean_object* x_224; lean_object* x_225; 
+lean_dec(x_214);
+lean_dec(x_50);
+x_223 = lean_ctor_get(x_218, 0);
+lean_inc(x_223);
+x_224 = lean_ctor_get(x_218, 1);
+lean_inc(x_224);
+lean_dec(x_218);
+x_225 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_225, 0, x_223);
+lean_ctor_set(x_225, 1, x_224);
+return x_225;
+}
+}
+else
+{
+lean_object* x_226; lean_object* x_227; lean_object* x_228; 
+lean_dec(x_214);
+lean_dec(x_50);
+lean_dec(x_30);
+lean_dec(x_13);
+lean_dec(x_8);
+lean_dec(x_6);
+lean_dec(x_5);
+lean_dec(x_4);
+lean_dec(x_3);
+lean_dec(x_2);
+x_226 = lean_ctor_get(x_216, 0);
+lean_inc(x_226);
+x_227 = lean_ctor_get(x_216, 1);
+lean_inc(x_227);
+lean_dec(x_216);
+x_228 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_228, 0, x_226);
+lean_ctor_set(x_228, 1, x_227);
+return x_228;
+}
+}
+else
 {
 lean_object* x_229; lean_object* x_230; lean_object* x_231; 
-x_229 = lean_ctor_get(x_228, 0);
+lean_dec(x_50);
+lean_dec(x_30);
+lean_dec(x_13);
+lean_dec(x_8);
+lean_dec(x_6);
+lean_dec(x_5);
+lean_dec(x_4);
+lean_dec(x_3);
+lean_dec(x_2);
+x_229 = lean_ctor_get(x_213, 0);
 lean_inc(x_229);
-x_230 = lean_ctor_get(x_228, 1);
+x_230 = lean_ctor_get(x_213, 1);
 lean_inc(x_230);
-lean_dec(x_228);
-x_231 = l_Lean_Elab_Term_Do_ToCodeBlock_checkNotShadowingMutable(x_229, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_230);
-if (lean_obj_tag(x_231) == 0)
+lean_dec(x_213);
+x_231 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_231, 0, x_229);
+lean_ctor_set(x_231, 1, x_230);
+return x_231;
+}
+}
+}
+else
 {
-lean_object* x_232; uint8_t x_233; lean_object* x_234; lean_object* x_235; 
-x_232 = lean_ctor_get(x_231, 1);
-lean_inc(x_232);
-lean_dec(x_231);
-lean_inc(x_46);
-x_233 = l_Lean_Elab_Term_Do_isMutableLet(x_46);
-x_234 = lean_alloc_closure((void*)(l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode), 9, 1);
-lean_closure_set(x_234, 0, x_13);
-lean_inc(x_229);
-x_235 = l_Lean_Elab_Term_Do_ToCodeBlock_withNewMutableVars___rarg(x_229, x_233, x_234, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_232);
+lean_object* x_232; 
+lean_dec(x_57);
+lean_inc(x_8);
+lean_inc(x_30);
+lean_inc(x_6);
+lean_inc(x_5);
+lean_inc(x_4);
+lean_inc(x_3);
+x_232 = l_Lean_Elab_Term_Do_getDoLetVars(x_50, x_3, x_4, x_5, x_6, x_30, x_8, x_48);
+if (lean_obj_tag(x_232) == 0)
+{
+lean_object* x_233; lean_object* x_234; lean_object* x_235; 
+x_233 = lean_ctor_get(x_232, 0);
+lean_inc(x_233);
+x_234 = lean_ctor_get(x_232, 1);
+lean_inc(x_234);
+lean_dec(x_232);
+x_235 = l_Lean_Elab_Term_Do_ToCodeBlock_checkNotShadowingMutable(x_233, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_234);
 if (lean_obj_tag(x_235) == 0)
 {
-lean_object* x_236; lean_object* x_237; lean_object* x_238; lean_object* x_239; 
-x_236 = lean_ctor_get(x_235, 0);
+lean_object* x_236; uint8_t x_237; lean_object* x_238; lean_object* x_239; 
+x_236 = lean_ctor_get(x_235, 1);
 lean_inc(x_236);
-x_237 = lean_ctor_get(x_235, 1);
-lean_inc(x_237);
 lean_dec(x_235);
-x_238 = l_Lean_Elab_Term_Do_mkVarDeclCore(x_229, x_46, x_236);
-x_239 = lean_alloc_ctor(0, 2, 0);
-lean_ctor_set(x_239, 0, x_238);
-lean_ctor_set(x_239, 1, x_237);
-return x_239;
-}
-else
+lean_inc(x_50);
+x_237 = l_Lean_Elab_Term_Do_isMutableLet(x_50);
+x_238 = lean_alloc_closure((void*)(l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode), 9, 1);
+lean_closure_set(x_238, 0, x_13);
+lean_inc(x_233);
+x_239 = l_Lean_Elab_Term_Do_ToCodeBlock_withNewMutableVars___rarg(x_233, x_237, x_238, x_2, x_3, x_4, x_5, x_6, x_30, x_8, x_236);
+if (lean_obj_tag(x_239) == 0)
 {
-lean_object* x_240; lean_object* x_241; lean_object* x_242; 
-lean_dec(x_229);
-lean_dec(x_46);
-x_240 = lean_ctor_get(x_235, 0);
+lean_object* x_240; lean_object* x_241; lean_object* x_242; lean_object* x_243; 
+x_240 = lean_ctor_get(x_239, 0);
 lean_inc(x_240);
-x_241 = lean_ctor_get(x_235, 1);
+x_241 = lean_ctor_get(x_239, 1);
 lean_inc(x_241);
-lean_dec(x_235);
-x_242 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_242, 0, x_240);
-lean_ctor_set(x_242, 1, x_241);
-return x_242;
-}
+lean_dec(x_239);
+x_242 = l_Lean_Elab_Term_Do_mkVarDeclCore(x_233, x_50, x_240);
+x_243 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_243, 0, x_242);
+lean_ctor_set(x_243, 1, x_241);
+return x_243;
 }
 else
 {
-lean_object* x_243; lean_object* x_244; lean_object* x_245; 
-lean_dec(x_229);
-lean_dec(x_46);
-lean_dec(x_30);
-lean_dec(x_13);
-lean_dec(x_8);
-lean_dec(x_6);
-lean_dec(x_5);
-lean_dec(x_4);
-lean_dec(x_3);
-lean_dec(x_2);
-x_243 = lean_ctor_get(x_231, 0);
-lean_inc(x_243);
-x_244 = lean_ctor_get(x_231, 1);
+lean_object* x_244; lean_object* x_245; lean_object* x_246; 
+lean_dec(x_233);
+lean_dec(x_50);
+x_244 = lean_ctor_get(x_239, 0);
 lean_inc(x_244);
-lean_dec(x_231);
-x_245 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_245, 0, x_243);
-lean_ctor_set(x_245, 1, x_244);
-return x_245;
+x_245 = lean_ctor_get(x_239, 1);
+lean_inc(x_245);
+lean_dec(x_239);
+x_246 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_246, 0, x_244);
+lean_ctor_set(x_246, 1, x_245);
+return x_246;
 }
 }
 else
 {
-lean_object* x_246; lean_object* x_247; lean_object* x_248; 
-lean_dec(x_46);
+lean_object* x_247; lean_object* x_248; lean_object* x_249; 
+lean_dec(x_233);
+lean_dec(x_50);
 lean_dec(x_30);
 lean_dec(x_13);
 lean_dec(x_8);
@@ -34518,22 +34825,21 @@
 lean_dec(x_4);
 lean_dec(x_3);
 lean_dec(x_2);
-x_246 = lean_ctor_get(x_228, 0);
-lean_inc(x_246);
-x_247 = lean_ctor_get(x_228, 1);
+x_247 = lean_ctor_get(x_235, 0);
 lean_inc(x_247);
-lean_dec(x_228);
-x_248 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_248, 0, x_246);
-lean_ctor_set(x_248, 1, x_247);
-return x_248;
-}
-}
+x_248 = lean_ctor_get(x_235, 1);
+lean_inc(x_248);
+lean_dec(x_235);
+x_249 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_249, 0, x_247);
+lean_ctor_set(x_249, 1, x_248);
+return x_249;
 }
 }
 else
 {
-lean_object* x_249; lean_object* x_250; lean_object* x_251; 
+lean_object* x_250; lean_object* x_251; lean_object* x_252; 
+lean_dec(x_50);
 lean_dec(x_30);
 lean_dec(x_13);
 lean_dec(x_8);
@@ -34542,81 +34848,65 @@
 lean_dec(x_4);
 lean_dec(x_3);
 lean_dec(x_2);
-x_249 = lean_ctor_get(x_42, 0);
-lean_inc(x_249);
-x_250 = lean_ctor_get(x_42, 1);
+x_250 = lean_ctor_get(x_232, 0);
 lean_inc(x_250);
-lean_dec(x_42);
-x_251 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_251, 0, x_249);
-lean_ctor_set(x_251, 1, x_250);
-return x_251;
+x_251 = lean_ctor_get(x_232, 1);
+lean_inc(x_251);
+lean_dec(x_232);
+x_252 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_252, 0, x_250);
+lean_ctor_set(x_252, 1, x_251);
+return x_252;
+}
+}
 }
 }
 else
 {
-lean_object* x_252; lean_object* x_253; lean_object* x_254; 
-lean_dec(x_12);
-x_252 = lean_ctor_get(x_39, 1);
-lean_inc(x_252);
-lean_dec(x_39);
-x_253 = lean_ctor_get(x_40, 0);
+lean_object* x_253; lean_object* x_254; lean_object* x_255; 
+lean_dec(x_30);
+lean_dec(x_13);
+lean_dec(x_8);
+lean_dec(x_6);
+lean_dec(x_5);
+lean_dec(x_4);
+lean_dec(x_3);
+lean_dec(x_2);
+x_253 = lean_ctor_get(x_46, 0);
 lean_inc(x_253);
-lean_dec(x_40);
-x_254 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_254, 0, x_253);
-lean_ctor_set(x_254, 1, x_13);
-x_1 = x_254;
-x_7 = x_30;
-x_9 = x_252;
-goto _start;
+x_254 = lean_ctor_get(x_46, 1);
+lean_inc(x_254);
+lean_dec(x_46);
+x_255 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_255, 0, x_253);
+lean_ctor_set(x_255, 1, x_254);
+return x_255;
 }
 }
 else
 {
-lean_object* x_256; lean_object* x_257; lean_object* x_258; 
-lean_dec(x_30);
+lean_object* x_256; lean_object* x_257; lean_object* x_258; lean_object* x_259; 
 lean_dec(x_13);
 lean_dec(x_12);
-lean_dec(x_8);
-lean_dec(x_6);
-lean_dec(x_5);
-lean_dec(x_4);
-lean_dec(x_3);
-lean_dec(x_2);
-x_256 = lean_ctor_get(x_39, 0);
+x_256 = lean_ctor_get(x_43, 1);
 lean_inc(x_256);
-x_257 = lean_ctor_get(x_39, 1);
+lean_dec(x_43);
+x_257 = lean_ctor_get(x_44, 0);
 lean_inc(x_257);
-lean_dec(x_39);
-x_258 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_258, 0, x_256);
-lean_ctor_set(x_258, 1, x_257);
-return x_258;
-}
-}
-else
-{
-lean_object* x_259; lean_object* x_260; lean_object* x_261; 
-lean_dec(x_12);
-x_259 = lean_ctor_get(x_35, 1);
-lean_inc(x_259);
-lean_dec(x_35);
-x_260 = lean_ctor_get(x_36, 0);
-lean_inc(x_260);
-lean_dec(x_36);
-x_261 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_261, 0, x_260);
-lean_ctor_set(x_261, 1, x_13);
-x_1 = x_261;
+lean_dec(x_44);
+x_258 = lean_box(0);
+x_259 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_259, 0, x_257);
+lean_ctor_set(x_259, 1, x_258);
+x_1 = x_259;
 x_7 = x_30;
-x_9 = x_259;
+x_9 = x_256;
 goto _start;
 }
 }
 else
 {
-lean_object* x_263; lean_object* x_264; lean_object* x_265; 
+lean_object* x_261; lean_object* x_262; lean_object* x_263; 
 lean_dec(x_30);
 lean_dec(x_13);
 lean_dec(x_12);
@@ -34626,20 +34916,39 @@
 lean_dec(x_4);
 lean_dec(x_3);
 lean_dec(x_2);
-x_263 = lean_ctor_get(x_35, 0);
-lean_inc(x_263);
-x_264 = lean_ctor_get(x_35, 1);
+x_261 = lean_ctor_get(x_43, 0);
+lean_inc(x_261);
+x_262 = lean_ctor_get(x_43, 1);
+lean_inc(x_262);
+lean_dec(x_43);
+x_263 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_263, 0, x_261);
+lean_ctor_set(x_263, 1, x_262);
+return x_263;
+}
+}
+else
+{
+lean_object* x_264; lean_object* x_265; lean_object* x_266; 
+lean_dec(x_12);
+x_264 = lean_ctor_get(x_39, 1);
 lean_inc(x_264);
-lean_dec(x_35);
-x_265 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_265, 0, x_263);
-lean_ctor_set(x_265, 1, x_264);
-return x_265;
+lean_dec(x_39);
+x_265 = lean_ctor_get(x_40, 0);
+lean_inc(x_265);
+lean_dec(x_40);
+x_266 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_266, 0, x_265);
+lean_ctor_set(x_266, 1, x_13);
+x_1 = x_266;
+x_7 = x_30;
+x_9 = x_264;
+goto _start;
 }
 }
 else
 {
-lean_object* x_266; lean_object* x_267; lean_object* x_268; 
+lean_object* x_268; lean_object* x_269; lean_object* x_270; 
 lean_dec(x_30);
 lean_dec(x_13);
 lean_dec(x_12);
@@ -34649,20 +34958,85 @@
 lean_dec(x_4);
 lean_dec(x_3);
 lean_dec(x_2);
-x_266 = lean_ctor_get(x_32, 0);
-lean_inc(x_266);
-x_267 = lean_ctor_get(x_32, 1);
-lean_inc(x_267);
-lean_dec(x_32);
-x_268 = lean_alloc_ctor(1, 2, 0);
-lean_ctor_set(x_268, 0, x_266);
-lean_ctor_set(x_268, 1, x_267);
-return x_268;
+x_268 = lean_ctor_get(x_39, 0);
+lean_inc(x_268);
+x_269 = lean_ctor_get(x_39, 1);
+lean_inc(x_269);
+lean_dec(x_39);
+x_270 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_270, 0, x_268);
+lean_ctor_set(x_270, 1, x_269);
+return x_270;
 }
 }
 else
 {
-lean_object* x_269; 
+lean_object* x_271; lean_object* x_272; lean_object* x_273; 
+lean_dec(x_12);
+x_271 = lean_ctor_get(x_35, 1);
+lean_inc(x_271);
+lean_dec(x_35);
+x_272 = lean_ctor_get(x_36, 0);
+lean_inc(x_272);
+lean_dec(x_36);
+x_273 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_273, 0, x_272);
+lean_ctor_set(x_273, 1, x_13);
+x_1 = x_273;
+x_7 = x_30;
+x_9 = x_271;
+goto _start;
+}
+}
+else
+{
+lean_object* x_275; lean_object* x_276; lean_object* x_277; 
+lean_dec(x_30);
+lean_dec(x_13);
+lean_dec(x_12);
+lean_dec(x_8);
+lean_dec(x_6);
+lean_dec(x_5);
+lean_dec(x_4);
+lean_dec(x_3);
+lean_dec(x_2);
+x_275 = lean_ctor_get(x_35, 0);
+lean_inc(x_275);
+x_276 = lean_ctor_get(x_35, 1);
+lean_inc(x_276);
+lean_dec(x_35);
+x_277 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_277, 0, x_275);
+lean_ctor_set(x_277, 1, x_276);
+return x_277;
+}
+}
+else
+{
+lean_object* x_278; lean_object* x_279; lean_object* x_280; 
+lean_dec(x_30);
+lean_dec(x_13);
+lean_dec(x_12);
+lean_dec(x_8);
+lean_dec(x_6);
+lean_dec(x_5);
+lean_dec(x_4);
+lean_dec(x_3);
+lean_dec(x_2);
+x_278 = lean_ctor_get(x_32, 0);
+lean_inc(x_278);
+x_279 = lean_ctor_get(x_32, 1);
+lean_inc(x_279);
+lean_dec(x_32);
+x_280 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_280, 0, x_278);
+lean_ctor_set(x_280, 1, x_279);
+return x_280;
+}
+}
+else
+{
+lean_object* x_281; 
 lean_dec(x_24);
 lean_dec(x_23);
 lean_dec(x_22);
@@ -34675,7 +35049,7 @@
 lean_dec(x_14);
 lean_dec(x_13);
 lean_dec(x_12);
-x_269 = l_Lean_throwMaxRecDepthAt___at_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___spec__4(x_19, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9);
+x_281 = l_Lean_throwMaxRecDepthAt___at_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___spec__4(x_19, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9);
 lean_dec(x_8);
 lean_dec(x_7);
 lean_dec(x_6);
@@ -34683,7 +35057,7 @@
 lean_dec(x_4);
 lean_dec(x_3);
 lean_dec(x_2);
-return x_269;
+return x_281;
 }
 }
 }
@@ -35008,7 +35382,7 @@
 x_82 = lean_ctor_get(x_80, 1);
 lean_inc(x_82);
 lean_dec(x_80);
-x_83 = l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__6;
+x_83 = l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__2;
 x_84 = lean_alloc_ctor(0, 3, 0);
 lean_ctor_set(x_84, 0, x_49);
 lean_ctor_set(x_84, 1, x_83);
@@ -38248,7 +38622,7 @@
 lean_inc(x_31);
 lean_inc(x_18);
 x_41 = l_Lean_Syntax_node3(x_18, x_40, x_28, x_31, x_39);
-x_42 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_42 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_18);
 x_43 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_43, 0, x_18);
@@ -38258,7 +38632,7 @@
 x_45 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___lambda__2___closed__5;
 lean_inc(x_18);
 x_46 = l_Lean_Syntax_node2(x_18, x_45, x_41, x_44);
-x_47 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_47 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_18);
 x_48 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_48, 0, x_18);
@@ -38351,7 +38725,7 @@
 lean_inc(x_79);
 lean_inc(x_66);
 x_89 = l_Lean_Syntax_node3(x_66, x_88, x_76, x_79, x_87);
-x_90 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_90 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_66);
 x_91 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_91, 0, x_66);
@@ -38362,7 +38736,7 @@
 lean_inc(x_92);
 lean_inc(x_66);
 x_94 = l_Lean_Syntax_node2(x_66, x_93, x_89, x_92);
-x_95 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_95 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_66);
 x_96 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_96, 0, x_66);
@@ -38533,7 +38907,7 @@
 lean_inc(x_31);
 lean_inc(x_19);
 x_41 = l_Lean_Syntax_node3(x_19, x_40, x_29, x_31, x_39);
-x_42 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_42 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_19);
 x_43 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_43, 0, x_19);
@@ -38545,25 +38919,25 @@
 lean_inc(x_44);
 lean_inc(x_19);
 x_46 = l_Lean_Syntax_node2(x_19, x_45, x_41, x_44);
-x_47 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_47 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_19);
 x_48 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_48, 0, x_19);
 lean_ctor_set(x_48, 1, x_47);
-x_49 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__13;
+x_49 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
 lean_inc(x_19);
 x_50 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_50, 0, x_19);
 lean_ctor_set(x_50, 1, x_49);
-x_51 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__18;
+x_51 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
 lean_inc(x_19);
 x_52 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_52, 0, x_19);
 lean_ctor_set(x_52, 1, x_51);
-x_53 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__15;
+x_53 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__14;
 lean_inc(x_19);
 x_54 = l_Lean_Syntax_node1(x_19, x_53, x_52);
-x_55 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
+x_55 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__11;
 lean_inc(x_50);
 lean_inc(x_33);
 lean_inc(x_19);
@@ -38582,7 +38956,7 @@
 x_63 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_63, 0, x_19);
 lean_ctor_set(x_63, 1, x_62);
-x_64 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
+x_64 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__15;
 lean_inc(x_19);
 x_65 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_65, 0, x_19);
@@ -39179,7 +39553,7 @@
 lean_ctor_set(x_60, 0, x_42);
 lean_ctor_set(x_60, 1, x_38);
 lean_ctor_set(x_60, 2, x_59);
-x_61 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_61 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_42);
 x_62 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_62, 0, x_42);
@@ -39367,7 +39741,7 @@
 lean_inc(x_60);
 lean_inc(x_42);
 x_141 = l_Lean_Syntax_node2(x_42, x_69, x_140, x_60);
-x_142 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__12;
+x_142 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__10;
 lean_inc(x_49);
 lean_inc(x_42);
 x_143 = l_Lean_Syntax_node2(x_42, x_142, x_49, x_4);
@@ -40380,25 +40754,25 @@
 x_229 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_229, 0, x_146);
 lean_ctor_set(x_229, 1, x_228);
-x_230 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_230 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_146);
 x_231 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_231, 0, x_146);
 lean_ctor_set(x_231, 1, x_230);
-x_232 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__13;
+x_232 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
 lean_inc(x_146);
 x_233 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_233, 0, x_146);
 lean_ctor_set(x_233, 1, x_232);
-x_234 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__18;
+x_234 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
 lean_inc(x_146);
 x_235 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_235, 0, x_146);
 lean_ctor_set(x_235, 1, x_234);
-x_236 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__15;
+x_236 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__14;
 lean_inc(x_146);
 x_237 = l_Lean_Syntax_node1(x_146, x_236, x_235);
-x_238 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
+x_238 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__11;
 lean_inc(x_209);
 lean_inc(x_146);
 x_239 = l_Lean_Syntax_node3(x_146, x_238, x_209, x_233, x_237);
@@ -40409,7 +40783,7 @@
 x_242 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__9;
 lean_inc(x_146);
 x_243 = l_Lean_Syntax_node1(x_146, x_242, x_241);
-x_244 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_244 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_146);
 x_245 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_245, 0, x_146);
@@ -40572,25 +40946,25 @@
 x_312 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_312, 0, x_146);
 lean_ctor_set(x_312, 1, x_311);
-x_313 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_313 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_146);
 x_314 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_314, 0, x_146);
 lean_ctor_set(x_314, 1, x_313);
-x_315 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__13;
+x_315 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
 lean_inc(x_146);
 x_316 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_316, 0, x_146);
 lean_ctor_set(x_316, 1, x_315);
-x_317 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__18;
+x_317 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
 lean_inc(x_146);
 x_318 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_318, 0, x_146);
 lean_ctor_set(x_318, 1, x_317);
-x_319 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__15;
+x_319 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__14;
 lean_inc(x_146);
 x_320 = l_Lean_Syntax_node1(x_146, x_319, x_318);
-x_321 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__12;
+x_321 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__11;
 lean_inc(x_292);
 lean_inc(x_146);
 x_322 = l_Lean_Syntax_node3(x_146, x_321, x_292, x_316, x_320);
@@ -40601,7 +40975,7 @@
 x_325 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__9;
 lean_inc(x_146);
 x_326 = l_Lean_Syntax_node1(x_146, x_325, x_324);
-x_327 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_327 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_146);
 x_328 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_328, 0, x_146);
@@ -41174,7 +41548,7 @@
 lean_inc(x_28);
 lean_inc(x_15);
 x_38 = l_Lean_Syntax_node3(x_15, x_37, x_25, x_28, x_36);
-x_39 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_39 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_15);
 x_40 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_40, 0, x_15);
@@ -41184,7 +41558,7 @@
 x_42 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___lambda__2___closed__5;
 lean_inc(x_15);
 x_43 = l_Lean_Syntax_node2(x_15, x_42, x_38, x_41);
-x_44 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_44 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_15);
 x_45 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_45, 0, x_15);
@@ -41383,7 +41757,7 @@
 lean_inc(x_48);
 lean_inc(x_35);
 x_58 = l_Lean_Syntax_node3(x_35, x_57, x_45, x_48, x_56);
-x_59 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_59 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_35);
 x_60 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_60, 0, x_35);
@@ -41393,7 +41767,7 @@
 x_62 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___lambda__2___closed__5;
 lean_inc(x_35);
 x_63 = l_Lean_Syntax_node2(x_35, x_62, x_58, x_61);
-x_64 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_64 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_35);
 x_65 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_65, 0, x_35);
@@ -41471,7 +41845,7 @@
 lean_ctor_set(x_29, 0, x_19);
 lean_ctor_set(x_29, 1, x_26);
 lean_ctor_set(x_29, 2, x_28);
-x_30 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_30 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_19);
 x_31 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_31, 0, x_19);
@@ -41749,7 +42123,7 @@
 lean_inc(x_35);
 lean_inc(x_20);
 x_45 = l_Lean_Syntax_node3(x_20, x_44, x_32, x_35, x_43);
-x_46 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_46 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_20);
 x_47 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_47, 0, x_20);
@@ -41907,7 +42281,7 @@
 lean_inc(x_28);
 lean_inc(x_16);
 x_41 = l_Lean_Syntax_node3(x_16, x_40, x_28, x_31, x_39);
-x_42 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_42 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_16);
 x_43 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_43, 0, x_16);
@@ -41917,7 +42291,7 @@
 x_45 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___lambda__2___closed__5;
 lean_inc(x_16);
 x_46 = l_Lean_Syntax_node2(x_16, x_45, x_41, x_44);
-x_47 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_47 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_16);
 x_48 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_48, 0, x_16);
@@ -42008,7 +42382,7 @@
 lean_inc(x_28);
 lean_inc(x_16);
 x_41 = l_Lean_Syntax_node3(x_16, x_40, x_28, x_31, x_39);
-x_42 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17;
+x_42 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16;
 lean_inc(x_16);
 x_43 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_43, 0, x_16);
@@ -42025,7 +42399,7 @@
 lean_ctor_set(x_48, 1, x_47);
 lean_inc(x_16);
 x_49 = l_Lean_Syntax_node1(x_16, x_29, x_48);
-x_50 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__10;
+x_50 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17;
 lean_inc(x_16);
 x_51 = lean_alloc_ctor(2, 2, 0);
 lean_ctor_set(x_51, 0, x_16);
@@ -43271,7 +43645,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1772u);
+x_1 = lean_unsigned_to_nat(1788u);
 x_2 = lean_unsigned_to_nat(26u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -43283,7 +43657,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1780u);
+x_1 = lean_unsigned_to_nat(1796u);
 x_2 = lean_unsigned_to_nat(84u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -43311,7 +43685,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1772u);
+x_1 = lean_unsigned_to_nat(1788u);
 x_2 = lean_unsigned_to_nat(30u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -43323,7 +43697,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1772u);
+x_1 = lean_unsigned_to_nat(1788u);
 x_2 = lean_unsigned_to_nat(36u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -43369,7 +43743,7 @@
 return x_4;
 }
 }
-static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__1() {
+static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__1() {
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
@@ -43379,27 +43753,27 @@
 return x_3;
 }
 }
-static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__2() {
+static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__2() {
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__1;
+x_1 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__1;
 x_2 = l___regBuiltin_Lean_Elab_Term_elabLiftMethod___closed__3;
 x_3 = l_Lean_Name_str___override(x_1, x_2);
 return x_3;
 }
 }
-static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__3() {
+static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__3() {
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__2;
+x_1 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__2;
 x_2 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__3;
 x_3 = l_Lean_Name_str___override(x_1, x_2);
 return x_3;
 }
 }
-static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__4() {
+static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__4() {
 _start:
 {
 lean_object* x_1; 
@@ -43407,17 +43781,17 @@
 return x_1;
 }
 }
-static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__5() {
+static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__5() {
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__3;
-x_2 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__4;
+x_1 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__3;
+x_2 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__4;
 x_3 = l_Lean_Name_str___override(x_1, x_2);
 return x_3;
 }
 }
-static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__6() {
+static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__6() {
 _start:
 {
 lean_object* x_1; 
@@ -43425,47 +43799,47 @@
 return x_1;
 }
 }
-static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__7() {
+static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__7() {
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__5;
-x_2 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__6;
+x_1 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__5;
+x_2 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__6;
 x_3 = l_Lean_Name_str___override(x_1, x_2);
 return x_3;
 }
 }
-static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__8() {
+static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__8() {
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__7;
+x_1 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__7;
 x_2 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_getDoSeqElems___closed__1;
 x_3 = l_Lean_Name_str___override(x_1, x_2);
 return x_3;
 }
 }
-static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__9() {
+static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__9() {
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__8;
+x_1 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__8;
 x_2 = l___regBuiltin_Lean_Elab_Term_elabLiftMethod___closed__3;
 x_3 = l_Lean_Name_str___override(x_1, x_2);
 return x_3;
 }
 }
-static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__10() {
+static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__10() {
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__9;
+x_1 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__9;
 x_2 = l___regBuiltin_Lean_Elab_Term_Do_elabDo___closed__1;
 x_3 = l_Lean_Name_str___override(x_1, x_2);
 return x_3;
 }
 }
-static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__11() {
+static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__11() {
 _start:
 {
 lean_object* x_1; 
@@ -43473,33 +43847,33 @@
 return x_1;
 }
 }
-static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__12() {
+static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__12() {
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__10;
-x_2 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__11;
+x_1 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__10;
+x_2 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__11;
 x_3 = l_Lean_Name_str___override(x_1, x_2);
 return x_3;
 }
 }
-static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__13() {
+static lean_object* _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__13() {
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__12;
-x_2 = lean_unsigned_to_nat(34501u);
+x_1 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__12;
+x_2 = lean_unsigned_to_nat(35132u);
 x_3 = l_Lean_Name_num___override(x_1, x_2);
 return x_3;
 }
 }
-LEAN_EXPORT lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501_(lean_object* x_1) {
+LEAN_EXPORT lean_object* l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132_(lean_object* x_1) {
 _start:
 {
 lean_object* x_2; uint8_t x_3; lean_object* x_4; lean_object* x_5; 
 x_2 = l_Lean_Elab_Term_Do_elabDo___closed__1;
 x_3 = 0;
-x_4 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__13;
+x_4 = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__13;
 x_5 = l_Lean_registerTraceClass(x_2, x_3, x_4, x_1);
 return x_5;
 }
@@ -43620,7 +43994,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1791u);
+x_1 = lean_unsigned_to_nat(1807u);
 x_2 = lean_unsigned_to_nat(0u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -43632,7 +44006,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1791u);
+x_1 = lean_unsigned_to_nat(1807u);
 x_2 = lean_unsigned_to_nat(57u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -43660,7 +44034,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1791u);
+x_1 = lean_unsigned_to_nat(1807u);
 x_2 = lean_unsigned_to_nat(4u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -43672,7 +44046,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1791u);
+x_1 = lean_unsigned_to_nat(1807u);
 x_2 = lean_unsigned_to_nat(17u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -43722,7 +44096,7 @@
 _start:
 {
 lean_object* x_4; lean_object* x_5; 
-x_4 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__10;
+x_4 = l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__8;
 x_5 = l___private_Lean_Elab_Do_0__Lean_Elab_Term_toDoElem(x_4, x_1, x_2, x_3);
 return x_5;
 }
@@ -43780,7 +44154,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1794u);
+x_1 = lean_unsigned_to_nat(1810u);
 x_2 = lean_unsigned_to_nat(0u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -43792,7 +44166,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1794u);
+x_1 = lean_unsigned_to_nat(1810u);
 x_2 = lean_unsigned_to_nat(57u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -43820,7 +44194,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1794u);
+x_1 = lean_unsigned_to_nat(1810u);
 x_2 = lean_unsigned_to_nat(4u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -43832,7 +44206,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1794u);
+x_1 = lean_unsigned_to_nat(1810u);
 x_2 = lean_unsigned_to_nat(17u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -43940,7 +44314,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1797u);
+x_1 = lean_unsigned_to_nat(1813u);
 x_2 = lean_unsigned_to_nat(0u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -43952,7 +44326,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1797u);
+x_1 = lean_unsigned_to_nat(1813u);
 x_2 = lean_unsigned_to_nat(63u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -43980,7 +44354,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1797u);
+x_1 = lean_unsigned_to_nat(1813u);
 x_2 = lean_unsigned_to_nat(4u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -43992,7 +44366,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1797u);
+x_1 = lean_unsigned_to_nat(1813u);
 x_2 = lean_unsigned_to_nat(20u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -44100,7 +44474,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1800u);
+x_1 = lean_unsigned_to_nat(1816u);
 x_2 = lean_unsigned_to_nat(0u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -44112,7 +44486,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1800u);
+x_1 = lean_unsigned_to_nat(1816u);
 x_2 = lean_unsigned_to_nat(63u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -44140,7 +44514,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1800u);
+x_1 = lean_unsigned_to_nat(1816u);
 x_2 = lean_unsigned_to_nat(4u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -44152,7 +44526,7 @@
 _start:
 {
 lean_object* x_1; lean_object* x_2; lean_object* x_3; 
-x_1 = lean_unsigned_to_nat(1800u);
+x_1 = lean_unsigned_to_nat(1816u);
 x_2 = lean_unsigned_to_nat(20u);
 x_3 = lean_alloc_ctor(0, 2, 0);
 lean_ctor_set(x_3, 0, x_1);
@@ -44727,6 +45101,42 @@
 lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___closed__5);
 l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___closed__6 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___closed__6();
 lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoIf_x3f___closed__6);
+l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__1 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__1();
+lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__1);
+l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__2 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__2();
+lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__2);
+l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__3 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__3();
+lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__3);
+l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__4 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__4();
+lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__4);
+l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__5 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__5();
+lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__5);
+l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__6 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__6();
+lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__6);
+l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__7 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__7();
+lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__7);
+l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__8 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__8();
+lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__8);
+l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__9 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__9();
+lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__9);
+l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__10 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__10();
+lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__10);
+l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__11 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__11();
+lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__11);
+l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__12 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__12();
+lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__12);
+l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__13 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__13();
+lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__13);
+l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__14 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__14();
+lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__14);
+l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__15 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__15();
+lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__15);
+l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__16 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__16();
+lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__16);
+l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17();
+lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__17);
+l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__18 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__18();
+lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_expandDoLetExpr_x3f___closed__18);
 l_Array_foldrMUnsafe_fold___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkTuple___spec__1___closed__1 = _init_l_Array_foldrMUnsafe_fold___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkTuple___spec__1___closed__1();
 lean_mark_persistent(l_Array_foldrMUnsafe_fold___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkTuple___spec__1___closed__1);
 l_Array_foldrMUnsafe_fold___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkTuple___spec__1___closed__2 = _init_l_Array_foldrMUnsafe_fold___at___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_mkTuple___spec__1___closed__2();
@@ -44785,8 +45195,6 @@
 lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__16);
 l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17();
 lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__17);
-l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__18 = _init_l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__18();
-lean_mark_persistent(l___private_Lean_Elab_Do_0__Lean_Elab_Term_Do_destructTuple_destruct___closed__18);
 l_Lean_Elab_Term_Do_annotate___rarg___lambda__1___closed__1 = _init_l_Lean_Elab_Term_Do_annotate___rarg___lambda__1___closed__1();
 lean_mark_persistent(l_Lean_Elab_Term_Do_annotate___rarg___lambda__1___closed__1);
 l_Lean_Elab_Term_Do_annotate___rarg___lambda__1___closed__2 = _init_l_Lean_Elab_Term_Do_annotate___rarg___lambda__1___closed__2();
@@ -45168,14 +45576,6 @@
 lean_mark_persistent(l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__2);
 l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__3 = _init_l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__3();
 lean_mark_persistent(l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__3);
-l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__4 = _init_l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__4();
-lean_mark_persistent(l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__4);
-l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__5 = _init_l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__5();
-lean_mark_persistent(l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__5);
-l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__6 = _init_l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__6();
-lean_mark_persistent(l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__6);
-l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__7 = _init_l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__7();
-lean_mark_persistent(l_Array_forInUnsafe_loop___at_Lean_Elab_Term_Do_ToTerm_toTerm_go___spec__2___closed__7);
 l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__1 = _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__1();
 lean_mark_persistent(l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__1);
 l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__2 = _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__2();
@@ -45208,16 +45608,6 @@
 lean_mark_persistent(l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__15);
 l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__16 = _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__16();
 lean_mark_persistent(l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__16);
-l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__17 = _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__17();
-lean_mark_persistent(l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__17);
-l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__18 = _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__18();
-lean_mark_persistent(l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__18);
-l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__19 = _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__19();
-lean_mark_persistent(l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__19);
-l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__20 = _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__20();
-lean_mark_persistent(l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__20);
-l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__21 = _init_l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__21();
-lean_mark_persistent(l_Lean_Elab_Term_Do_ToTerm_toTerm_go___closed__21);
 l_Lean_Elab_Term_Do_ToTerm_mkNestedKind___closed__1 = _init_l_Lean_Elab_Term_Do_ToTerm_mkNestedKind___closed__1();
 lean_mark_persistent(l_Lean_Elab_Term_Do_ToTerm_mkNestedKind___closed__1);
 l_Lean_Elab_Term_Do_ToTerm_mkNestedKind___closed__2 = _init_l_Lean_Elab_Term_Do_ToTerm_mkNestedKind___closed__2();
@@ -45387,10 +45777,6 @@
 lean_mark_persistent(l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__13);
 l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__14 = _init_l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__14();
 lean_mark_persistent(l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__14);
-l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__15 = _init_l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__15();
-lean_mark_persistent(l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__15);
-l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__16 = _init_l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__16();
-lean_mark_persistent(l_Lean_Elab_Term_Do_ToCodeBlock_doSeqToCode___closed__16);
 l_Array_mapMUnsafe_map___at_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode___spec__2___closed__1 = _init_l_Array_mapMUnsafe_map___at_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode___spec__2___closed__1();
 lean_mark_persistent(l_Array_mapMUnsafe_map___at_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode___spec__2___closed__1);
 l_Array_mapMUnsafe_map___at_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode___spec__2___closed__2 = _init_l_Array_mapMUnsafe_map___at_Lean_Elab_Term_Do_ToCodeBlock_doTryToCode___spec__2___closed__2();
@@ -45609,33 +45995,33 @@
 if (builtin) {res = l___regBuiltin_Lean_Elab_Term_Do_elabDo_declRange(lean_io_mk_world());
 if (lean_io_result_is_error(res)) return res;
 lean_dec_ref(res);
-}l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__1 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__1();
-lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__1);
-l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__2 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__2();
-lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__2);
-l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__3 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__3();
-lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__3);
-l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__4 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__4();
-lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__4);
-l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__5 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__5();
-lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__5);
-l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__6 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__6();
-lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__6);
-l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__7 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__7();
-lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__7);
-l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__8 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__8();
-lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__8);
-l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__9 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__9();
-lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__9);
-l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__10 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__10();
-lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__10);
-l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__11 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__11();
-lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__11);
-l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__12 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__12();
-lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__12);
-l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__13 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__13();
-lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501____closed__13);
-if (builtin) {res = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_34501_(lean_io_mk_world());
+}l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__1 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__1();
+lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__1);
+l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__2 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__2();
+lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__2);
+l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__3 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__3();
+lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__3);
+l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__4 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__4();
+lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__4);
+l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__5 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__5();
+lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__5);
+l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__6 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__6();
+lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__6);
+l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__7 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__7();
+lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__7);
+l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__8 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__8();
+lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__8);
+l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__9 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__9();
+lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__9);
+l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__10 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__10();
+lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__10);
+l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__11 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__11();
+lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__11);
+l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__12 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__12();
+lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__12);
+l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__13 = _init_l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__13();
+lean_mark_persistent(l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132____closed__13);
+if (builtin) {res = l_Lean_Elab_Term_initFn____x40_Lean_Elab_Do___hyg_35132_(lean_io_mk_world());
 if (lean_io_result_is_error(res)) return res;
 lean_dec_ref(res);
 }l___regBuiltin_Lean_Elab_Term_expandTermFor___closed__1 = _init_l___regBuiltin_Lean_Elab_Term_expandTermFor___closed__1();
diff --git a/stage0/stdlib/Lean/Elab/MatchExpr.c b/stage0/stdlib/Lean/Elab/MatchExpr.c
index 28e55a0..e69165f 100644
--- a/stage0/stdlib/Lean/Elab/MatchExpr.c
+++ b/stage0/stdlib/Lean/Elab/MatchExpr.c
@@ -28,6 +28,7 @@
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_MatchExpr_getParams(lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_MatchExpr_getActuals___lambda__1___closed__2;
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate_loop___lambda__2___closed__30;
+static lean_object* l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__6;
 static lean_object* l_Lean_Elab_Term_MatchExpr_toDoubleQuotedName___closed__6;
 static lean_object* l_Lean_Elab_Term_MatchExpr_toElseAlt_x3f___closed__1;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_MatchExpr_getParams___lambda__2___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
@@ -36,7 +37,11 @@
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate___closed__23;
 static lean_object* l_Lean_Elab_Term_MatchExpr_toAlt_x3f___lambda__1___closed__3;
 static lean_object* l_Lean_Elab_Term_MatchExpr_toDoubleQuotedName___closed__7;
+static lean_object* l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__4;
+static lean_object* l_Lean_Elab_Term_expandLetExpr___closed__2;
 LEAN_EXPORT lean_object* l_Array_filterMapM___at_Lean_Elab_Term_MatchExpr_getParams___spec__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
+static lean_object* l_Lean_Elab_Term_expandLetExpr___closed__4;
+static lean_object* l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__1;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_MatchExpr_toDoubleQuotedName(lean_object*);
 lean_object* l_Lean_Syntax_getId(lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_MatchExpr_Alt_k___default;
@@ -44,8 +49,10 @@
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate_loop___lambda__2___closed__5;
 static lean_object* l_List_forIn_loop___at_Lean_Elab_Term_MatchExpr_generate_loop___spec__1___closed__2;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_MatchExpr_getParams___lambda__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
+static lean_object* l_Lean_Elab_Term_expandLetExpr___closed__3;
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate___closed__1;
 LEAN_EXPORT lean_object* l_List_forIn_loop___at_Lean_Elab_Term_MatchExpr_generate___spec__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
+static lean_object* l_Lean_Elab_Term_expandLetExpr___closed__6;
 uint8_t lean_usize_dec_eq(size_t, size_t);
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate_loop___lambda__2___closed__9;
 lean_object* l_Lean_Syntax_getArgs(lean_object*);
@@ -90,6 +97,7 @@
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate_loop___lambda__2___closed__8;
 lean_object* l_Array_reverse___rarg(lean_object*);
 LEAN_EXPORT lean_object* l_List_mapM_loop___at_Lean_Elab_Term_MatchExpr_main___spec__1(lean_object*, lean_object*, lean_object*, lean_object*);
+static lean_object* l_Lean_Elab_Term_expandLetExpr___closed__5;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_MatchExpr_shouldSaveActual___boxed(lean_object*);
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate_loop___lambda__2___closed__16;
 static lean_object* l_Lean_Elab_Term_MatchExpr_toAlt_x3f___lambda__1___closed__4;
@@ -100,6 +108,7 @@
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate_loop___lambda__2___closed__38;
 lean_object* l_Lean_Syntax_node6(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_MatchExpr_getParams___spec__2___closed__9;
+LEAN_EXPORT lean_object* l_Lean_Elab_Term_expandLetExpr(lean_object*, lean_object*, lean_object*);
 static lean_object* l___regBuiltin_Lean_Elab_Term_expandMatchExpr___closed__4;
 static lean_object* l_Lean_Elab_Term_expandMatchExpr___closed__1;
 static lean_object* l_List_forIn_loop___at_Lean_Elab_Term_MatchExpr_generate___spec__2___closed__3;
@@ -119,6 +128,7 @@
 static lean_object* l_List_forIn_loop___at_Lean_Elab_Term_MatchExpr_getFunNamesToMatch___spec__2___closed__3;
 lean_object* lean_array_to_list(lean_object*, lean_object*);
 static lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_MatchExpr_getParams___spec__2___closed__1;
+static lean_object* l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__3;
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate_loop___lambda__2___closed__15;
 lean_object* l_Lean_Syntax_node3(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate_loop___lambda__2___closed__36;
@@ -135,6 +145,7 @@
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate___closed__20;
 uint8_t lean_name_eq(lean_object*, lean_object*);
 lean_object* l_Lean_Name_str___override(lean_object*, lean_object*);
+static lean_object* l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__2;
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate___closed__18;
 extern lean_object* l_Lean_Elab_macroAttribute;
 static lean_object* l_Lean_Elab_Term_expandMatchExpr___closed__2;
@@ -149,6 +160,8 @@
 static lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_MatchExpr_getParams___spec__2___closed__15;
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate_loop___lambda__2___closed__23;
 LEAN_EXPORT uint8_t l_Lean_Elab_Term_MatchExpr_shouldSaveActual(lean_object*);
+static lean_object* l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__5;
+static lean_object* l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__3;
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate___closed__14;
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate_loop___lambda__2___closed__21;
 static lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_MatchExpr_getParams___spec__2___closed__2;
@@ -157,6 +170,7 @@
 lean_object* l_Array_append___rarg(lean_object*, lean_object*);
 static lean_object* l___regBuiltin_Lean_Elab_Term_expandMatchExpr_declRange___closed__3;
 static lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_MatchExpr_getParams___spec__2___closed__10;
+static lean_object* l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__1;
 static lean_object* l_Lean_Elab_Term_MatchExpr_getParams___lambda__2___closed__1;
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate_loop___lambda__2___closed__40;
 lean_object* l_Lean_Syntax_node4(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
@@ -178,6 +192,7 @@
 uint8_t lean_nat_dec_lt(lean_object*, lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_MatchExpr_next(lean_object*, lean_object*);
 static lean_object* l___regBuiltin_Lean_Elab_Term_expandMatchExpr_declRange___closed__1;
+LEAN_EXPORT lean_object* l___regBuiltin_Lean_Elab_Term_expandLetExpr(lean_object*);
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_MatchExpr_generate_loop___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 lean_object* l_Lean_Name_mkStr2(lean_object*, lean_object*);
 static lean_object* l_List_forIn_loop___at_Lean_Elab_Term_MatchExpr_generate_loop___spec__1___closed__6;
@@ -193,6 +208,7 @@
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate___closed__24;
 uint8_t l_Lean_Syntax_isNone(lean_object*);
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate_loop___lambda__2___closed__10;
+static lean_object* l_Lean_Elab_Term_expandLetExpr___closed__1;
 LEAN_EXPORT lean_object* l_Lean_Elab_Term_MatchExpr_generate_loop(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate_loop___lambda__2___closed__35;
 static lean_object* l_Lean_Elab_Term_MatchExpr_toAlt_x3f___lambda__1___closed__5;
@@ -229,6 +245,7 @@
 static lean_object* l_Lean_Elab_Term_MatchExpr_getActuals___lambda__1___closed__1;
 static lean_object* l_Lean_Elab_Term_MatchExpr_toDoubleQuotedName___closed__2;
 lean_object* lean_array_get_size(lean_object*);
+static lean_object* l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__7;
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate_loop___lambda__2___closed__2;
 uint8_t lean_nat_dec_le(lean_object*, lean_object*);
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate___closed__10;
@@ -236,9 +253,11 @@
 static lean_object* l_Lean_Elab_Term_MatchExpr_toDoubleQuotedName___closed__1;
 static lean_object* l_List_forIn_loop___at_Lean_Elab_Term_MatchExpr_generate_loop___spec__1___closed__15;
 static lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_MatchExpr_getParams___spec__2___closed__14;
+static lean_object* l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__2;
 LEAN_EXPORT lean_object* l_Array_forInUnsafe_loop___at_Lean_Elab_Term_MatchExpr_getFunNamesToMatch___spec__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*);
 lean_object* lean_nat_add(lean_object*, lean_object*);
 static lean_object* l_List_mapM_loop___at_Lean_Elab_Term_MatchExpr_main___spec__1___closed__1;
+LEAN_EXPORT lean_object* l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange(lean_object*);
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate___closed__13;
 static lean_object* l___regBuiltin_Lean_Elab_Term_expandMatchExpr___closed__3;
 LEAN_EXPORT uint8_t l_Lean_Elab_Term_MatchExpr_shouldSaveActual___lambda__1(lean_object*);
@@ -256,6 +275,7 @@
 static lean_object* l_Lean_Elab_Term_MatchExpr_initK___closed__3;
 static lean_object* l_Lean_Elab_Term_MatchExpr_toAlt_x3f___closed__3;
 lean_object* l_List_toArrayAux___rarg(lean_object*, lean_object*);
+static lean_object* l_Lean_Elab_Term_expandLetExpr___closed__7;
 static lean_object* l_Lean_Elab_Term_MatchExpr_generate___closed__15;
 static lean_object* l_List_forIn_loop___at_Lean_Elab_Term_MatchExpr_generate_loop___spec__1___closed__9;
 static lean_object* l___regBuiltin_Lean_Elab_Term_expandMatchExpr___closed__2;
@@ -4547,6 +4567,317 @@
 return x_4;
 }
 }
+static lean_object* _init_l_Lean_Elab_Term_expandLetExpr___closed__1() {
+_start:
+{
+lean_object* x_1; 
+x_1 = lean_mk_string_from_bytes("letExpr", 7);
+return x_1;
+}
+}
+static lean_object* _init_l_Lean_Elab_Term_expandLetExpr___closed__2() {
+_start:
+{
+lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; 
+x_1 = l_Lean_Elab_Term_MatchExpr_toElseAlt_x3f___closed__1;
+x_2 = l_Lean_Elab_Term_MatchExpr_toElseAlt_x3f___closed__2;
+x_3 = l_Lean_Elab_Term_MatchExpr_toElseAlt_x3f___closed__3;
+x_4 = l_Lean_Elab_Term_expandLetExpr___closed__1;
+x_5 = l_Lean_Name_mkStr4(x_1, x_2, x_3, x_4);
+return x_5;
+}
+}
+static lean_object* _init_l_Lean_Elab_Term_expandLetExpr___closed__3() {
+_start:
+{
+lean_object* x_1; 
+x_1 = lean_mk_string_from_bytes("match_expr", 10);
+return x_1;
+}
+}
+static lean_object* _init_l_Lean_Elab_Term_expandLetExpr___closed__4() {
+_start:
+{
+lean_object* x_1; 
+x_1 = lean_mk_string_from_bytes("with", 4);
+return x_1;
+}
+}
+static lean_object* _init_l_Lean_Elab_Term_expandLetExpr___closed__5() {
+_start:
+{
+lean_object* x_1; 
+x_1 = lean_mk_string_from_bytes("matchExprAlts", 13);
+return x_1;
+}
+}
+static lean_object* _init_l_Lean_Elab_Term_expandLetExpr___closed__6() {
+_start:
+{
+lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; 
+x_1 = l_Lean_Elab_Term_MatchExpr_toElseAlt_x3f___closed__1;
+x_2 = l_Lean_Elab_Term_MatchExpr_toElseAlt_x3f___closed__2;
+x_3 = l_Lean_Elab_Term_MatchExpr_toElseAlt_x3f___closed__3;
+x_4 = l_Lean_Elab_Term_expandLetExpr___closed__5;
+x_5 = l_Lean_Name_mkStr4(x_1, x_2, x_3, x_4);
+return x_5;
+}
+}
+static lean_object* _init_l_Lean_Elab_Term_expandLetExpr___closed__7() {
+_start:
+{
+lean_object* x_1; 
+x_1 = lean_mk_string_from_bytes("|", 1);
+return x_1;
+}
+}
+LEAN_EXPORT lean_object* l_Lean_Elab_Term_expandLetExpr(lean_object* x_1, lean_object* x_2, lean_object* x_3) {
+_start:
+{
+lean_object* x_4; uint8_t x_5; 
+x_4 = l_Lean_Elab_Term_expandLetExpr___closed__2;
+lean_inc(x_1);
+x_5 = l_Lean_Syntax_isOfKind(x_1, x_4);
+if (x_5 == 0)
+{
+lean_object* x_6; lean_object* x_7; 
+lean_dec(x_2);
+lean_dec(x_1);
+x_6 = lean_box(1);
+x_7 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_7, 0, x_6);
+lean_ctor_set(x_7, 1, x_3);
+return x_7;
+}
+else
+{
+lean_object* x_8; lean_object* x_9; lean_object* x_10; uint8_t x_11; 
+x_8 = lean_unsigned_to_nat(1u);
+x_9 = l_Lean_Syntax_getArg(x_1, x_8);
+x_10 = l_Lean_Elab_Term_MatchExpr_toAlt_x3f___closed__4;
+lean_inc(x_9);
+x_11 = l_Lean_Syntax_isOfKind(x_9, x_10);
+if (x_11 == 0)
+{
+lean_object* x_12; lean_object* x_13; 
+lean_dec(x_9);
+lean_dec(x_2);
+lean_dec(x_1);
+x_12 = lean_box(1);
+x_13 = lean_alloc_ctor(1, 2, 0);
+lean_ctor_set(x_13, 0, x_12);
+lean_ctor_set(x_13, 1, x_3);
+return x_13;
+}
+else
+{
+lean_object* x_14; lean_object* x_15; lean_object* x_16; lean_object* x_17; lean_object* x_18; lean_object* x_19; lean_object* x_20; uint8_t x_21; lean_object* x_22; lean_object* x_23; lean_object* x_24; lean_object* x_25; lean_object* x_26; lean_object* x_27; lean_object* x_28; lean_object* x_29; lean_object* x_30; lean_object* x_31; lean_object* x_32; lean_object* x_33; lean_object* x_34; lean_object* x_35; lean_object* x_36; lean_object* x_37; lean_object* x_38; lean_object* x_39; lean_object* x_40; lean_object* x_41; lean_object* x_42; lean_object* x_43; lean_object* x_44; lean_object* x_45; 
+x_14 = lean_unsigned_to_nat(3u);
+x_15 = l_Lean_Syntax_getArg(x_1, x_14);
+x_16 = lean_unsigned_to_nat(5u);
+x_17 = l_Lean_Syntax_getArg(x_1, x_16);
+x_18 = lean_unsigned_to_nat(7u);
+x_19 = l_Lean_Syntax_getArg(x_1, x_18);
+lean_dec(x_1);
+x_20 = lean_ctor_get(x_2, 5);
+lean_inc(x_20);
+lean_dec(x_2);
+x_21 = 0;
+x_22 = l_Lean_SourceInfo_fromRef(x_20, x_21);
+x_23 = l_Lean_Elab_Term_expandLetExpr___closed__3;
+lean_inc(x_22);
+x_24 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_24, 0, x_22);
+lean_ctor_set(x_24, 1, x_23);
+x_25 = l_Lean_Elab_Term_expandLetExpr___closed__4;
+lean_inc(x_22);
+x_26 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_26, 0, x_22);
+lean_ctor_set(x_26, 1, x_25);
+x_27 = l_Lean_Elab_Term_expandLetExpr___closed__7;
+lean_inc(x_22);
+x_28 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_28, 0, x_22);
+lean_ctor_set(x_28, 1, x_27);
+x_29 = l_List_forIn_loop___at_Lean_Elab_Term_MatchExpr_generate___spec__2___closed__3;
+lean_inc(x_22);
+x_30 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_30, 0, x_22);
+lean_ctor_set(x_30, 1, x_29);
+x_31 = l_Lean_Elab_Term_MatchExpr_toAlt_x3f___closed__2;
+lean_inc(x_30);
+lean_inc(x_28);
+lean_inc(x_22);
+x_32 = l_Lean_Syntax_node4(x_22, x_31, x_28, x_9, x_30, x_19);
+x_33 = l_Array_foldlMUnsafe_fold___at_Lean_Elab_Term_MatchExpr_getParams___spec__2___closed__6;
+lean_inc(x_22);
+x_34 = l_Lean_Syntax_node1(x_22, x_33, x_32);
+x_35 = l_Lean_Elab_Term_MatchExpr_getParams___lambda__2___closed__1;
+lean_inc(x_22);
+x_36 = lean_alloc_ctor(2, 2, 0);
+lean_ctor_set(x_36, 0, x_22);
+lean_ctor_set(x_36, 1, x_35);
+x_37 = l_Lean_Elab_Term_MatchExpr_toAlt_x3f___lambda__1___closed__4;
+lean_inc(x_22);
+x_38 = l_Lean_Syntax_node1(x_22, x_37, x_36);
+x_39 = l_Lean_Elab_Term_MatchExpr_toElseAlt_x3f___closed__5;
+lean_inc(x_22);
+x_40 = l_Lean_Syntax_node4(x_22, x_39, x_28, x_38, x_30, x_17);
+x_41 = l_Lean_Elab_Term_expandLetExpr___closed__6;
+lean_inc(x_22);
+x_42 = l_Lean_Syntax_node2(x_22, x_41, x_34, x_40);
+x_43 = l_Lean_Elab_Term_expandMatchExpr___closed__2;
+x_44 = l_Lean_Syntax_node4(x_22, x_43, x_24, x_15, x_26, x_42);
+x_45 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_45, 0, x_44);
+lean_ctor_set(x_45, 1, x_3);
+return x_45;
+}
+}
+}
+}
+static lean_object* _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__1() {
+_start:
+{
+lean_object* x_1; 
+x_1 = lean_mk_string_from_bytes("expandLetExpr", 13);
+return x_1;
+}
+}
+static lean_object* _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__2() {
+_start:
+{
+lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; 
+x_1 = l_Lean_Elab_Term_MatchExpr_toElseAlt_x3f___closed__1;
+x_2 = l___regBuiltin_Lean_Elab_Term_expandMatchExpr___closed__1;
+x_3 = l_Lean_Elab_Term_MatchExpr_toElseAlt_x3f___closed__3;
+x_4 = l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__1;
+x_5 = l_Lean_Name_mkStr4(x_1, x_2, x_3, x_4);
+return x_5;
+}
+}
+static lean_object* _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__3() {
+_start:
+{
+lean_object* x_1; 
+x_1 = lean_alloc_closure((void*)(l_Lean_Elab_Term_expandLetExpr), 3, 0);
+return x_1;
+}
+}
+LEAN_EXPORT lean_object* l___regBuiltin_Lean_Elab_Term_expandLetExpr(lean_object* x_1) {
+_start:
+{
+lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; lean_object* x_6; 
+x_2 = l___regBuiltin_Lean_Elab_Term_expandMatchExpr___closed__4;
+x_3 = l_Lean_Elab_Term_expandLetExpr___closed__2;
+x_4 = l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__2;
+x_5 = l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__3;
+x_6 = l_Lean_KeyedDeclsAttribute_addBuiltin___rarg(x_2, x_3, x_4, x_5, x_1);
+return x_6;
+}
+}
+static lean_object* _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__1() {
+_start:
+{
+lean_object* x_1; lean_object* x_2; lean_object* x_3; 
+x_1 = lean_unsigned_to_nat(203u);
+x_2 = lean_unsigned_to_nat(42u);
+x_3 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_3, 0, x_1);
+lean_ctor_set(x_3, 1, x_2);
+return x_3;
+}
+}
+static lean_object* _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__2() {
+_start:
+{
+lean_object* x_1; lean_object* x_2; lean_object* x_3; 
+x_1 = lean_unsigned_to_nat(209u);
+x_2 = lean_unsigned_to_nat(31u);
+x_3 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_3, 0, x_1);
+lean_ctor_set(x_3, 1, x_2);
+return x_3;
+}
+}
+static lean_object* _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__3() {
+_start:
+{
+lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; 
+x_1 = l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__1;
+x_2 = lean_unsigned_to_nat(42u);
+x_3 = l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__2;
+x_4 = lean_unsigned_to_nat(31u);
+x_5 = lean_alloc_ctor(0, 4, 0);
+lean_ctor_set(x_5, 0, x_1);
+lean_ctor_set(x_5, 1, x_2);
+lean_ctor_set(x_5, 2, x_3);
+lean_ctor_set(x_5, 3, x_4);
+return x_5;
+}
+}
+static lean_object* _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__4() {
+_start:
+{
+lean_object* x_1; lean_object* x_2; lean_object* x_3; 
+x_1 = lean_unsigned_to_nat(203u);
+x_2 = lean_unsigned_to_nat(46u);
+x_3 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_3, 0, x_1);
+lean_ctor_set(x_3, 1, x_2);
+return x_3;
+}
+}
+static lean_object* _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__5() {
+_start:
+{
+lean_object* x_1; lean_object* x_2; lean_object* x_3; 
+x_1 = lean_unsigned_to_nat(203u);
+x_2 = lean_unsigned_to_nat(59u);
+x_3 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_3, 0, x_1);
+lean_ctor_set(x_3, 1, x_2);
+return x_3;
+}
+}
+static lean_object* _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__6() {
+_start:
+{
+lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; 
+x_1 = l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__4;
+x_2 = lean_unsigned_to_nat(46u);
+x_3 = l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__5;
+x_4 = lean_unsigned_to_nat(59u);
+x_5 = lean_alloc_ctor(0, 4, 0);
+lean_ctor_set(x_5, 0, x_1);
+lean_ctor_set(x_5, 1, x_2);
+lean_ctor_set(x_5, 2, x_3);
+lean_ctor_set(x_5, 3, x_4);
+return x_5;
+}
+}
+static lean_object* _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__7() {
+_start:
+{
+lean_object* x_1; lean_object* x_2; lean_object* x_3; 
+x_1 = l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__3;
+x_2 = l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__6;
+x_3 = lean_alloc_ctor(0, 2, 0);
+lean_ctor_set(x_3, 0, x_1);
+lean_ctor_set(x_3, 1, x_2);
+return x_3;
+}
+}
+LEAN_EXPORT lean_object* l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange(lean_object* x_1) {
+_start:
+{
+lean_object* x_2; lean_object* x_3; lean_object* x_4; 
+x_2 = l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__2;
+x_3 = l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__7;
+x_4 = l_Lean_addBuiltinDeclarationRanges(x_2, x_3, x_1);
+return x_4;
+}
+}
 lean_object* initialize_Lean_Elab_Term(uint8_t builtin, lean_object*);
 static bool _G_initialized = false;
 LEAN_EXPORT lean_object* initialize_Lean_Elab_MatchExpr(uint8_t builtin, lean_object* w) {
@@ -4866,6 +5197,46 @@
 if (builtin) {res = l___regBuiltin_Lean_Elab_Term_expandMatchExpr_declRange(lean_io_mk_world());
 if (lean_io_result_is_error(res)) return res;
 lean_dec_ref(res);
+}l_Lean_Elab_Term_expandLetExpr___closed__1 = _init_l_Lean_Elab_Term_expandLetExpr___closed__1();
+lean_mark_persistent(l_Lean_Elab_Term_expandLetExpr___closed__1);
+l_Lean_Elab_Term_expandLetExpr___closed__2 = _init_l_Lean_Elab_Term_expandLetExpr___closed__2();
+lean_mark_persistent(l_Lean_Elab_Term_expandLetExpr___closed__2);
+l_Lean_Elab_Term_expandLetExpr___closed__3 = _init_l_Lean_Elab_Term_expandLetExpr___closed__3();
+lean_mark_persistent(l_Lean_Elab_Term_expandLetExpr___closed__3);
+l_Lean_Elab_Term_expandLetExpr___closed__4 = _init_l_Lean_Elab_Term_expandLetExpr___closed__4();
+lean_mark_persistent(l_Lean_Elab_Term_expandLetExpr___closed__4);
+l_Lean_Elab_Term_expandLetExpr___closed__5 = _init_l_Lean_Elab_Term_expandLetExpr___closed__5();
+lean_mark_persistent(l_Lean_Elab_Term_expandLetExpr___closed__5);
+l_Lean_Elab_Term_expandLetExpr___closed__6 = _init_l_Lean_Elab_Term_expandLetExpr___closed__6();
+lean_mark_persistent(l_Lean_Elab_Term_expandLetExpr___closed__6);
+l_Lean_Elab_Term_expandLetExpr___closed__7 = _init_l_Lean_Elab_Term_expandLetExpr___closed__7();
+lean_mark_persistent(l_Lean_Elab_Term_expandLetExpr___closed__7);
+l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__1 = _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__1();
+lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__1);
+l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__2 = _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__2();
+lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__2);
+l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__3 = _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__3();
+lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_expandLetExpr___closed__3);
+if (builtin) {res = l___regBuiltin_Lean_Elab_Term_expandLetExpr(lean_io_mk_world());
+if (lean_io_result_is_error(res)) return res;
+lean_dec_ref(res);
+}l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__1 = _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__1();
+lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__1);
+l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__2 = _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__2();
+lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__2);
+l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__3 = _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__3();
+lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__3);
+l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__4 = _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__4();
+lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__4);
+l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__5 = _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__5();
+lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__5);
+l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__6 = _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__6();
+lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__6);
+l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__7 = _init_l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__7();
+lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange___closed__7);
+if (builtin) {res = l___regBuiltin_Lean_Elab_Term_expandLetExpr_declRange(lean_io_mk_world());
+if (lean_io_result_is_error(res)) return res;
+lean_dec_ref(res);
 }return lean_io_result_mk_ok(lean_box(0));
 }
 #ifdef __cplusplus