From 9c5668515ce9925d739635cd79a7fa2d09a24667 Mon Sep 17 00:00:00 2001 From: Leonardo de Moura Date: Fri, 14 Jan 2022 19:21:29 -0800 Subject: [PATCH] chore: update stage0 --- stage0/src/Lean/Compiler/ExternAttr.lean | 24 +- stage0/src/Lean/Compiler/IR/Basic.lean | 4 + stage0/src/Lean/Elab/DefView.lean | 2 +- stage0/src/Lean/Elab/Extra.lean | 2 - stage0/src/library/compiler/compiler.cpp | 2 +- .../src/library/compiler/extern_attribute.cpp | 16 +- .../src/library/compiler/extern_attribute.h | 1 + .../compiler/implemented_by_attribute.h | 3 + stage0/src/library/compiler/ir.cpp | 12 +- stage0/stdlib/Lean/Compiler/ExternAttr.c | 1325 +++++++++-------- stage0/stdlib/Lean/Compiler/IR/Basic.c | 16 + stage0/stdlib/Lean/Elab/DefView.c | 274 ++-- stage0/stdlib/Lean/Elab/Extra.c | 383 ++++- stage0/stdlib/Lean/PrettyPrinter/Basic.c | 6 +- 14 files changed, 1228 insertions(+), 842 deletions(-) diff --git a/stage0/src/Lean/Compiler/ExternAttr.lean b/stage0/src/Lean/Compiler/ExternAttr.lean index c61be64b25..f09dabb72a 100644 --- a/stage0/src/Lean/Compiler/ExternAttr.lean +++ b/stage0/src/Lean/Compiler/ExternAttr.lean @@ -138,23 +138,25 @@ def getExternNameFor (env : Environment) (backend : Name) (fn : Name) : Option S | ExternEntry.foreign _ n => pure n | _ => failure -def getExternConstArity (declName : Name) : CoreM (Option Nat) := do +private def getExternConstArity (declName : Name) : CoreM Nat := do + let fromSignature : Unit → CoreM Nat := fun _ => do + let cinfo ← getConstInfo declName + let (arity, _) ← (Meta.forallTelescopeReducing cinfo.type fun xs _ => pure xs.size : MetaM Nat).run + return arity let env ← getEnv match getExternAttrData env declName with - | none => pure none + | none => fromSignature () | some data => match data.arity? with - | some arity => pure arity - | none => - let cinfo ← getConstInfo declName - let (arity, _) ← (Meta.forallTelescopeReducing cinfo.type fun xs _ => pure xs.size : MetaM Nat).run - pure (some arity) + | some arity => return arity + | none => fromSignature () @[export lean_get_extern_const_arity] def getExternConstArityExport (env : Environment) (declName : Name) : IO (Option Nat) := do try - let (arity?, _) ← (getExternConstArity declName).toIO {} { env := env } - pure arity? - catch _ => - pure none + let (arity, _) ← (getExternConstArity declName).toIO {} { env := env } + return some arity + catch + | IO.Error.userError msg => return none + | _ => return none end Lean diff --git a/stage0/src/Lean/Compiler/IR/Basic.lean b/stage0/src/Lean/Compiler/IR/Basic.lean index dc0ace49a4..fe936a11dd 100644 --- a/stage0/src/Lean/Compiler/IR/Basic.lean +++ b/stage0/src/Lean/Compiler/IR/Basic.lean @@ -438,6 +438,10 @@ end Decl @[export lean_ir_mk_extern_decl] def mkExternDecl (f : FunId) (xs : Array Param) (ty : IRType) (e : ExternAttrData) : Decl := Decl.extern f xs ty e +-- Hack: we use this declaration as a stub for declarations annotated with `implementedBy` or `init` +@[export lean_ir_mk_dummy_extern_decl] def mkDummyExternDecl (f : FunId) (xs : Array Param) (ty : IRType) : Decl := + Decl.fdecl f xs ty FnBody.unreachable {} + open Std (RBTree RBTree.empty RBMap) /-- Set of variable and join point names -/ diff --git a/stage0/src/Lean/Elab/DefView.lean b/stage0/src/Lean/Elab/DefView.lean index 09b804cc16..731c4573a3 100644 --- a/stage0/src/Lean/Elab/DefView.lean +++ b/stage0/src/Lean/Elab/DefView.lean @@ -132,7 +132,7 @@ def mkDefViewOfConstant (modifiers : Modifiers) (stx : Syntax) : CommandElabM De let val ← match stx[3].getOptional? with | some val => pure val | none => - let val ← `(arbitrary) + let val ← `(arbitrary_or_ofNonempty%) pure $ mkNode ``Parser.Command.declValSimple #[ mkAtomFrom stx ":=", val ] return { ref := stx, kind := DefKind.opaque, modifiers := modifiers, diff --git a/stage0/src/Lean/Elab/Extra.lean b/stage0/src/Lean/Elab/Extra.lean index e9648c651d..cfad6e47a0 100644 --- a/stage0/src/Lean/Elab/Extra.lean +++ b/stage0/src/Lean/Elab/Extra.lean @@ -313,7 +313,6 @@ def elabBinCalc : TermElab := fun stx expectedType? => do pure () ensureHasType expectedType? result -/- @[builtinTermElab arbitraryOrOfNonempty] def elabArbitraryOrNonempty : TermElab := fun stx expectedType? => do tryPostponeIfNoneOrMVar expectedType? @@ -326,7 +325,6 @@ def elabArbitraryOrNonempty : TermElab := fun stx expectedType? => do mkOfNonempty expectedType catch _ => throw ex --/ builtin_initialize registerTraceClass `Elab.binop diff --git a/stage0/src/library/compiler/compiler.cpp b/stage0/src/library/compiler/compiler.cpp index 5a2bc6ddc9..c36a7fb409 100644 --- a/stage0/src/library/compiler/compiler.cpp +++ b/stage0/src/library/compiler/compiler.cpp @@ -185,7 +185,7 @@ environment compile(environment const & env, options const & opts, names cs) { if (length(cs) == 1) { name c = get_real_name(head(cs)); - if (is_extern_constant(env, c)) { + if (skip_code_generation(env, c)) { /* Generate boxed version for extern/native constant if needed. */ return ir::add_extern(env, c); } diff --git a/stage0/src/library/compiler/extern_attribute.cpp b/stage0/src/library/compiler/extern_attribute.cpp index e8dd0d0b20..7dd9a9aec2 100644 --- a/stage0/src/library/compiler/extern_attribute.cpp +++ b/stage0/src/library/compiler/extern_attribute.cpp @@ -14,6 +14,8 @@ Authors: Leonardo de Moura #include "library/util.h" #include "library/projection.h" #include "library/compiler/borrowed_annotation.h" +#include "library/compiler/init_attribute.h" +#include "library/compiler/implemented_by_attribute.h" #include "library/compiler/util.h" #include "library/compiler/ir.h" #include "library/compiler/extern_attribute.h" @@ -29,6 +31,18 @@ bool is_extern_constant(environment const & env, name const & c) { return static_cast(get_extern_attr_data(env, c)); } +bool skip_code_generation(environment const & env, name const & c) { + if (is_extern_constant(env, c)) { + return true; + } else if (auto info = env.find(c)) { + // `declarations marked with `init` + return info->is_opaque() && has_init_attribute(env, c); + } else { + // `declarations marked with `implementedBy` + return has_implemented_by_attribute(env, c); + } +} + extern "C" object * lean_get_extern_const_arity(object* env, object*, object* w); optional get_extern_constant_arity(environment const & env, name const & c) { @@ -68,7 +82,7 @@ bool get_extern_borrowed_info(environment const & env, name const & c, buffer get_extern_constant_ll_type(environment const & env, name const & c) { - if (is_extern_constant(env, c)) { + if (skip_code_generation(env, c)) { unsigned arity = 0; expr type = env.get(c).get_type(); type_checker::state st(env); diff --git a/stage0/src/library/compiler/extern_attribute.h b/stage0/src/library/compiler/extern_attribute.h index 51d3db1308..db6ed58817 100644 --- a/stage0/src/library/compiler/extern_attribute.h +++ b/stage0/src/library/compiler/extern_attribute.h @@ -9,6 +9,7 @@ Authors: Leonardo de Moura #include "kernel/environment.h" namespace lean { bool is_extern_constant(environment const & env, name const & c); +bool skip_code_generation(environment const & env, name const & c); optional get_extern_constant_ll_type(environment const & env, name const & c); optional get_extern_constant_arity(environment const & env, name const & c); typedef object_ref extern_attr_data_value; diff --git a/stage0/src/library/compiler/implemented_by_attribute.h b/stage0/src/library/compiler/implemented_by_attribute.h index a02d709764..375cb3ba37 100644 --- a/stage0/src/library/compiler/implemented_by_attribute.h +++ b/stage0/src/library/compiler/implemented_by_attribute.h @@ -9,4 +9,7 @@ Author: Leonardo de Moura namespace lean { optional get_implemented_by_attribute(environment const & env, name const & n); +inline bool has_implemented_by_attribute(environment const & env, name const & n) { + return static_cast(get_implemented_by_attribute(env, n)); +} } diff --git a/stage0/src/library/compiler/ir.cpp b/stage0/src/library/compiler/ir.cpp index 61b9fcee82..50f2c53eb8 100644 --- a/stage0/src/library/compiler/ir.cpp +++ b/stage0/src/library/compiler/ir.cpp @@ -40,6 +40,7 @@ extern "C" object * lean_ir_mk_jmp(object * j, object * ys); extern "C" object * lean_ir_mk_alt(object * n, object * cidx, object * size, object * usize, object * ssize, object * b); extern "C" object * lean_ir_mk_decl(object * f, object * xs, object * ty, object * b); extern "C" object * lean_ir_mk_extern_decl(object * f, object * xs, object * ty, object * ext_entry); +extern "C" object * lean_ir_mk_dummy_extern_decl(object * f, object * xs, object * ty); extern "C" object * lean_ir_decl_to_string(object * d); extern "C" object * lean_ir_compile(object * env, object * opts, object * decls); extern "C" object * lean_ir_log_to_string(object * log); @@ -92,6 +93,9 @@ decl mk_decl(fun_id const & f, buffer const & xs, type ty, fn_body const decl mk_extern_decl(fun_id const & f, buffer const & xs, type ty, extern_attr_data_value const & v) { return decl(lean_ir_mk_extern_decl(f.to_obj_arg(), to_array(xs), box_type(ty), v.to_obj_arg())); } +decl mk_dummy_extern_decl(fun_id const & f, buffer const & xs, type ty) { + return decl(lean_ir_mk_dummy_extern_decl(f.to_obj_arg(), to_array(xs), box_type(ty))); +} std::string decl_to_string(decl const & d) { string_ref r(lean_ir_decl_to_string(d.to_obj_arg())); return r.to_std_string(); @@ -492,8 +496,12 @@ public: type = binding_body(type); } ir::type result_type = to_ir_type(type); - extern_attr_data_value attr = *get_extern_attr_data(env(), fn); - return ir::mk_extern_decl(fn, xs, result_type, attr); + if (optional attr = get_extern_attr_data(env(), fn)) { + return ir::mk_extern_decl(fn, xs, result_type, *attr); + } else { + // Hack: `fn` is marked with `implementedBy` or `init` + return ir::mk_dummy_extern_decl(fn, xs, result_type); + } } }; diff --git a/stage0/stdlib/Lean/Compiler/ExternAttr.c b/stage0/stdlib/Lean/Compiler/ExternAttr.c index 585a26a00a..d612e421cb 100644 --- a/stage0/stdlib/Lean/Compiler/ExternAttr.c +++ b/stage0/stdlib/Lean/Compiler/ExternAttr.c @@ -18,14 +18,15 @@ lean_object* l_Lean_addMessageContextPartial___at_Lean_Core_instAddMessageContex static lean_object* l_Lean_mkSimpleFnCall___closed__2; size_t lean_usize_add(size_t, size_t); lean_object* lean_io_get_num_heartbeats(lean_object*); -static lean_object* l_Lean_getExternConstArity___closed__12; lean_object* l_Lean_stringToMessageData(lean_object*); LEAN_EXPORT lean_object* l_Lean_getExternEntryForAux(lean_object*, lean_object*); -LEAN_EXPORT lean_object* l_Lean_getExternConstArity___lambda__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__3; lean_object* lean_mk_empty_array_with_capacity(lean_object*); +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__15; static lean_object* l_Lean_externAttr___closed__5; lean_object* l_List_getD___rarg(lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_initFn____x40_Lean_Compiler_ExternAttr___hyg_398____lambda__3(lean_object*, lean_object*, lean_object*); +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__18; LEAN_EXPORT lean_object* lean_get_extern_const_arity(lean_object*, lean_object*, lean_object*); lean_object* lean_name_mk_string(lean_object*, lean_object*); lean_object* lean_array_uget(lean_object*, size_t); @@ -37,35 +38,32 @@ static lean_object* l_Lean_getExternConstArityExport___closed__1; lean_object* l_Lean_Meta_forallTelescopeReducing___at_Lean_Meta_getParamNames___spec__2___rarg(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_parseOptNum(lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_instInhabitedExternAttrData; +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__14; +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__5; lean_object* lean_environment_find(lean_object*, lean_object*); static lean_object* l_Lean_instInhabitedExternAttrData___closed__1; -static lean_object* l_Lean_getExternConstArity___closed__19; lean_object* l___private_Init_Meta_0__Lean_Syntax_isNatLitAux(lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_expandExternPattern(lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_initFn____x40_Lean_Compiler_ExternAttr___hyg_398____lambda__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__6; lean_object* lean_st_ref_get(lean_object*, lean_object*); uint8_t lean_name_eq(lean_object*, lean_object*); static lean_object* l_Lean_initFn____x40_Lean_Compiler_ExternAttr___hyg_398____closed__4; static lean_object* l_Lean_externAttr___closed__9; -static lean_object* l_Lean_getExternConstArity___closed__11; -LEAN_EXPORT lean_object* l_Lean_throwError___at_Lean_getExternConstArity___spec__2___boxed(lean_object*, lean_object*, lean_object*, lean_object*); lean_object* lean_array_push(lean_object*, lean_object*); lean_object* lean_array_get_size(lean_object*); lean_object* lean_string_append(lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_ExternEntry_backend___boxed(lean_object*); LEAN_EXPORT lean_object* l_Lean_getExternNameFor(lean_object*, lean_object*, lean_object*); -static lean_object* l_Lean_getExternConstArity___closed__2; +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__22; LEAN_EXPORT lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_syntaxToExternAttrData___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); static lean_object* l_Lean_externAttr___closed__4; static lean_object* l_Lean_externAttr___closed__10; LEAN_EXPORT lean_object* l_Lean_externAttr___lambda__4(lean_object*, lean_object*); uint8_t lean_usize_dec_lt(size_t, size_t); -static lean_object* l_Lean_getExternConstArity___closed__8; static uint8_t l_Lean_expandExternPatternAux___closed__1; static lean_object* l_Lean_externAttr___closed__11; lean_object* lean_nat_add(lean_object*, lean_object*); -static lean_object* l_Lean_getExternConstArity___closed__17; -static lean_object* l_Lean_getExternConstArity___closed__4; LEAN_EXPORT lean_object* l_Lean_throwError___at___private_Lean_Compiler_ExternAttr_0__Lean_syntaxToExternAttrData___spec__2___boxed(lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_externAttr___lambda__2___boxed(lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_externAttr___lambda__3(lean_object*, lean_object*, lean_object*); @@ -74,13 +72,17 @@ LEAN_EXPORT lean_object* l_Lean_initFn____x40_Lean_Compiler_ExternAttr___hyg_398 LEAN_EXPORT lean_object* l_Lean_externAttr___lambda__6___boxed(lean_object*); LEAN_EXPORT lean_object* l_Lean_externAttr___lambda__5___boxed(lean_object*); uint8_t l_Lean_Environment_isConstructor(lean_object*, lean_object*); +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__21; +LEAN_EXPORT lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_expandExternPattern___boxed(lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_ExternEntry_backend(lean_object*); -static lean_object* l_Lean_getExternConstArity___closed__9; LEAN_EXPORT uint8_t l_Lean_isExternC(lean_object*, lean_object*); +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__13; +static lean_object* l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__1; uint8_t lean_nat_dec_eq(lean_object*, lean_object*); uint8_t l_instDecidableNot___rarg(uint8_t); LEAN_EXPORT uint8_t l_Lean_isExtern(lean_object*, lean_object*); +LEAN_EXPORT lean_object* l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*); lean_object* lean_add_extern(lean_object*, lean_object*); lean_object* l_Lean_MessageData_toString(lean_object*, lean_object*); static lean_object* l_Lean_getExternConstArityExport___closed__5; @@ -90,7 +92,6 @@ LEAN_EXPORT lean_object* l_Lean_ExternAttrData_arity_x3f___default; LEAN_EXPORT lean_object* l_Lean_expandExternPatternAux___boxed(lean_object*, lean_object*, lean_object*, lean_object*); static lean_object* l_Lean_getExternConstArityExport___closed__3; lean_object* l_Lean_Syntax_isStrLit_x3f(lean_object*); -static lean_object* l_Lean_getExternConstArity___closed__13; LEAN_EXPORT lean_object* l_Lean_externAttr___lambda__6(lean_object*); static lean_object* l_Lean_getExternConstArityExport___closed__4; static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_syntaxToExternAttrData___closed__1; @@ -99,42 +100,43 @@ static lean_object* l_Lean_externAttr___lambda__1___closed__2; lean_object* l_Lean_replaceRef(lean_object*, lean_object*); static uint8_t l_Lean_expandExternPatternAux___closed__2; static lean_object* l_Lean_getExternConstArityExport___closed__2; +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__17; +LEAN_EXPORT lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___lambda__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__4; static lean_object* l_Lean_externAttr___lambda__1___closed__1; LEAN_EXPORT lean_object* l_Lean_externAttr___lambda__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); -static lean_object* l_Lean_getExternConstArity___closed__21; -LEAN_EXPORT lean_object* l_Lean_getExternConstArity___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_ofExcept___at_Lean_initFn____x40_Lean_Class___hyg_759____spec__1(lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_initFn____x40_Lean_Compiler_ExternAttr___hyg_398____lambda__2___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); static lean_object* l_Lean_initFn____x40_Lean_Compiler_ExternAttr___hyg_398____closed__6; static lean_object* l_Lean_externAttr___closed__6; -static lean_object* l_Lean_getExternConstArity___closed__22; +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__8; lean_object* lean_st_mk_ref(lean_object*, lean_object*); static lean_object* l_Lean_initFn____x40_Lean_Compiler_ExternAttr___hyg_398____closed__1; lean_object* l_Lean_Core_getMaxHeartbeats(lean_object*); lean_object* l_Lean_Syntax_getId(lean_object*); extern lean_object* l_Lean_Expr_instHashableExpr; -static lean_object* l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__4; lean_object* l_Std_PersistentHashMap_mkEmptyEntriesArray(lean_object*, lean_object*); +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__2; static lean_object* l_Lean_initFn____x40_Lean_Compiler_ExternAttr___hyg_398____closed__2; +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__1; lean_object* lean_array_to_list(lean_object*, lean_object*); lean_object* l_Lean_Meta_InfoCacheKey_instHashableInfoCacheKey___boxed(lean_object*); static lean_object* l_Lean_initFn____x40_Lean_Compiler_ExternAttr___hyg_398____closed__8; -static lean_object* l_Lean_getExternConstArity___closed__1; +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__9; LEAN_EXPORT lean_object* l_Lean_isExtern___boxed(lean_object*, lean_object*); static lean_object* l_Lean_externAttr___closed__2; static lean_object* l_Lean_externAttr___lambda__3___closed__3; -LEAN_EXPORT lean_object* l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*); -static lean_object* l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__1; extern lean_object* l_Lean_firstFrontendMacroScope; static lean_object* l_Lean_initFn____x40_Lean_Compiler_ExternAttr___hyg_398____closed__3; +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__19; LEAN_EXPORT lean_object* l_Array_forInUnsafe_loop___at___private_Lean_Compiler_ExternAttr_0__Lean_syntaxToExternAttrData___spec__3___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_String_Iterator_next(lean_object*); +LEAN_EXPORT lean_object* l_Lean_throwError___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__2___boxed(lean_object*, lean_object*, lean_object*, lean_object*); static lean_object* l_Array_forInUnsafe_loop___at___private_Lean_Compiler_ExternAttr_0__Lean_syntaxToExternAttrData___spec__3___closed__3; LEAN_EXPORT lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_syntaxToExternAttrData(lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_externAttr___lambda__5(lean_object*); size_t lean_usize_of_nat(lean_object*); uint8_t l___private_Init_Data_Option_Basic_0__beqOption____x40_Init_Data_Option_Basic___hyg_802____at___private_Lean_Meta_Basic_0__Lean_Meta_beqInfoCacheKey____x40_Lean_Meta_Basic___hyg_323____spec__1(lean_object*, lean_object*); -LEAN_EXPORT lean_object* l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1(lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_ConstantInfo_type(lean_object*); lean_object* l_instBEqProd___rarg(lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_throwErrorAt___at___private_Lean_Compiler_ExternAttr_0__Lean_syntaxToExternAttrData___spec__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); @@ -144,28 +146,22 @@ extern lean_object* l_Lean_projectionFnInfoExt; static lean_object* l_Lean_mkSimpleFnCall___closed__3; lean_object* l_Lean_EnvExtensionInterfaceUnsafe_instInhabitedExt___lambda__1(lean_object*); LEAN_EXPORT lean_object* l_Lean_isExternC___boxed(lean_object*, lean_object*); +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__11; LEAN_EXPORT lean_object* l_Lean_externAttr___lambda__2(lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_setEnv___at_Lean_registerTagAttribute___spec__2(lean_object*, lean_object*, lean_object*, lean_object*); -static lean_object* l_Lean_getExternConstArity___closed__3; LEAN_EXPORT lean_object* lean_get_extern_attr_data(lean_object*, lean_object*); uint8_t lean_uint32_dec_eq(uint32_t, uint32_t); LEAN_EXPORT lean_object* l_Lean_initFn____x40_Lean_Compiler_ExternAttr___hyg_398_(lean_object*); -static lean_object* l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__2; -static lean_object* l_Lean_getExternConstArity___closed__5; -static lean_object* l_Lean_getExternConstArity___closed__14; -static lean_object* l_Lean_getExternConstArity___closed__15; -static lean_object* l_Lean_getExternConstArity___closed__18; +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__12; +static lean_object* l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__2; static lean_object* l_Lean_initFn____x40_Lean_Compiler_ExternAttr___hyg_398____closed__7; lean_object* l_Lean_Syntax_getArgs(lean_object*); static lean_object* l_Lean_externAttr___closed__7; -static lean_object* l_Lean_getExternConstArity___closed__10; LEAN_EXPORT lean_object* l_Lean_externAttr___lambda__3___boxed(lean_object*, lean_object*, lean_object*); uint32_t l_String_Iterator_curr(lean_object*); static uint32_t l_Lean_externAttr___lambda__3___closed__1; lean_object* l_List_intersperse___rarg(lean_object*, lean_object*); -static lean_object* l_Lean_getExternConstArity___closed__20; lean_object* l_Lean_ParametricAttribute_getParam___rarg(lean_object*, lean_object*, lean_object*, lean_object*); -LEAN_EXPORT lean_object* l_Lean_throwError___at_Lean_getExternConstArity___spec__2(lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_addExtern___boxed(lean_object*, lean_object*); static lean_object* l_Lean_externAttr___closed__8; LEAN_EXPORT lean_object* l_Lean_getExternEntryFor(lean_object*, lean_object*); @@ -175,42 +171,46 @@ LEAN_EXPORT lean_object* l_Array_forInUnsafe_loop___at___private_Lean_Compiler_E static lean_object* l_Lean_externAttr___lambda__3___closed__2; LEAN_EXPORT lean_object* l_Array_forInUnsafe_loop___at___private_Lean_Compiler_ExternAttr_0__Lean_syntaxToExternAttrData___spec__3___lambda__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* lean_nat_mul(lean_object*, lean_object*); -static lean_object* l_Lean_getExternConstArity___closed__16; +LEAN_EXPORT lean_object* l_Lean_throwError___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__2(lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_expandExternPatternAux(lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_getExternEntryForAux___boxed(lean_object*, lean_object*); uint8_t l_Lean_Syntax_isNone(lean_object*); -static lean_object* l_Lean_getExternConstArity___closed__7; static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_syntaxToExternAttrData___closed__4; lean_object* l_instHashableProd___rarg___boxed(lean_object*, lean_object*, lean_object*); uint8_t l_Lean_MapDeclarationExtension_contains___rarg(lean_object*, lean_object*, lean_object*, lean_object*); +static lean_object* l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__3; static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_syntaxToExternAttrData___closed__2; static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_syntaxToExternAttrData___lambda__1___closed__1; extern lean_object* l_Lean_Expr_instBEqExpr; +LEAN_EXPORT lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity(lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_syntaxToExternAttrData___lambda__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_registerParametricAttribute___rarg(lean_object*, lean_object*, lean_object*); -static lean_object* l_Lean_getExternConstArity___closed__6; lean_object* lean_string_length(lean_object*); LEAN_EXPORT lean_object* l_Lean_externAttr___lambda__1(lean_object*, lean_object*, uint8_t, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Syntax_getArg(lean_object*, lean_object*); static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_syntaxToExternAttrData___closed__3; lean_object* l_String_Iterator_remainingBytes(lean_object*); static lean_object* l_Lean_mkSimpleFnCall___closed__1; +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__7; +LEAN_EXPORT lean_object* l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1(lean_object*, lean_object*, lean_object*, lean_object*); +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__16; uint8_t lean_uint32_dec_le(uint32_t, uint32_t); uint32_t lean_uint32_of_nat(lean_object*); LEAN_EXPORT lean_object* l_Lean_mkSimpleFnCall(lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_initFn____x40_Lean_Compiler_ExternAttr___hyg_398____lambda__3___boxed(lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_initFn____x40_Lean_Compiler_ExternAttr___hyg_398____lambda__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_getExternEntryFor___boxed(lean_object*, lean_object*); +static lean_object* l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__4; LEAN_EXPORT lean_object* l_Lean_externAttr; lean_object* l_Lean_mkConst(lean_object*, lean_object*); lean_object* lean_uint32_to_nat(uint32_t); static lean_object* l_Lean_externAttr___closed__12; -static lean_object* l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__3; +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__10; +static lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__20; LEAN_EXPORT lean_object* l_Array_forInUnsafe_loop___at___private_Lean_Compiler_ExternAttr_0__Lean_syntaxToExternAttrData___spec__3___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); static lean_object* l_Array_forInUnsafe_loop___at___private_Lean_Compiler_ExternAttr_0__Lean_syntaxToExternAttrData___spec__3___closed__2; static lean_object* l_Array_forInUnsafe_loop___at___private_Lean_Compiler_ExternAttr_0__Lean_syntaxToExternAttrData___spec__3___closed__1; uint8_t lean_string_dec_eq(lean_object*, lean_object*); -LEAN_EXPORT lean_object* l_Lean_getExternConstArity(lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_externAttr___lambda__4___boxed(lean_object*, lean_object*); static lean_object* _init_l_Lean_ExternAttrData_arity_x3f___default() { _start: @@ -2126,7 +2126,7 @@ lean_dec(x_2); return x_4; } } -LEAN_EXPORT lean_object* l_Lean_throwError___at_Lean_getExternConstArity___spec__2(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4) { +LEAN_EXPORT lean_object* l_Lean_throwError___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__2(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4) { _start: { lean_object* x_5; lean_object* x_6; uint8_t x_7; @@ -2164,7 +2164,7 @@ return x_13; } } } -static lean_object* _init_l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__1() { +static lean_object* _init_l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__1() { _start: { lean_object* x_1; @@ -2172,16 +2172,16 @@ x_1 = lean_mk_string("unknown constant '"); return x_1; } } -static lean_object* _init_l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__2() { +static lean_object* _init_l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__2() { _start: { lean_object* x_1; lean_object* x_2; -x_1 = l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__1; +x_1 = l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__1; x_2 = l_Lean_stringToMessageData(x_1); return x_2; } } -static lean_object* _init_l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__3() { +static lean_object* _init_l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__3() { _start: { lean_object* x_1; @@ -2189,16 +2189,16 @@ x_1 = lean_mk_string("'"); return x_1; } } -static lean_object* _init_l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__4() { +static lean_object* _init_l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__4() { _start: { lean_object* x_1; lean_object* x_2; -x_1 = l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__3; +x_1 = l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__3; x_2 = l_Lean_stringToMessageData(x_1); return x_2; } } -LEAN_EXPORT lean_object* l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4) { +LEAN_EXPORT lean_object* l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1(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; @@ -2222,15 +2222,15 @@ x_11 = lean_box(0); x_12 = l_Lean_mkConst(x_1, x_11); x_13 = lean_alloc_ctor(2, 1, 0); lean_ctor_set(x_13, 0, x_12); -x_14 = l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__2; +x_14 = l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__2; x_15 = lean_alloc_ctor(10, 2, 0); lean_ctor_set(x_15, 0, x_14); lean_ctor_set(x_15, 1, x_13); -x_16 = l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__4; +x_16 = l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__4; x_17 = lean_alloc_ctor(10, 2, 0); lean_ctor_set(x_17, 0, x_15); lean_ctor_set(x_17, 1, x_16); -x_18 = l_Lean_throwError___at_Lean_getExternConstArity___spec__2(x_17, x_2, x_3, x_8); +x_18 = l_Lean_throwError___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__2(x_17, x_2, x_3, x_8); return x_18; } else @@ -2264,15 +2264,15 @@ x_24 = lean_box(0); x_25 = l_Lean_mkConst(x_1, x_24); x_26 = lean_alloc_ctor(2, 1, 0); lean_ctor_set(x_26, 0, x_25); -x_27 = l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__2; +x_27 = l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__2; x_28 = lean_alloc_ctor(10, 2, 0); lean_ctor_set(x_28, 0, x_27); lean_ctor_set(x_28, 1, x_26); -x_29 = l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__4; +x_29 = l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__4; x_30 = lean_alloc_ctor(10, 2, 0); lean_ctor_set(x_30, 0, x_28); lean_ctor_set(x_30, 1, x_29); -x_31 = l_Lean_throwError___at_Lean_getExternConstArity___spec__2(x_30, x_2, x_3, x_21); +x_31 = l_Lean_throwError___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__2(x_30, x_2, x_3, x_21); return x_31; } else @@ -2290,7 +2290,7 @@ return x_33; } } } -LEAN_EXPORT lean_object* l_Lean_getExternConstArity___lambda__1(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_EXPORT lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___lambda__1(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) { _start: { lean_object* x_8; lean_object* x_9; @@ -2301,7 +2301,7 @@ lean_ctor_set(x_9, 1, x_7); return x_9; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__1() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__1() { _start: { uint8_t x_1; uint8_t x_2; uint8_t x_3; lean_object* x_4; @@ -2326,7 +2326,7 @@ lean_ctor_set_uint8(x_4, 13, x_3); return x_4; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__2() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__2() { _start: { lean_object* x_1; @@ -2334,21 +2334,21 @@ x_1 = l_Std_PersistentHashMap_mkEmptyEntriesArray(lean_box(0), lean_box(0)); return x_1; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__3() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__3() { _start: { lean_object* x_1; lean_object* x_2; -x_1 = l_Lean_getExternConstArity___closed__2; +x_1 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__2; 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_getExternConstArity___closed__4() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__4() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = l_Lean_getExternConstArity___closed__3; +x_1 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__3; x_2 = lean_unsigned_to_nat(0u); x_3 = lean_alloc_ctor(0, 2, 0); lean_ctor_set(x_3, 0, x_1); @@ -2356,7 +2356,7 @@ lean_ctor_set(x_3, 1, x_2); return x_3; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__5() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__5() { _start: { lean_object* x_1; lean_object* x_2; @@ -2365,23 +2365,23 @@ x_2 = lean_mk_empty_array_with_capacity(x_1); return x_2; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__6() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__6() { _start: { lean_object* x_1; lean_object* x_2; -x_1 = l_Lean_getExternConstArity___closed__5; +x_1 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__5; 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_getExternConstArity___closed__7() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__7() { _start: { size_t x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; x_1 = 5; -x_2 = l_Lean_getExternConstArity___closed__6; -x_3 = l_Lean_getExternConstArity___closed__5; +x_2 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__6; +x_3 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__5; x_4 = lean_unsigned_to_nat(0u); x_5 = lean_alloc_ctor(0, 4, sizeof(size_t)*1); lean_ctor_set(x_5, 0, x_2); @@ -2392,25 +2392,25 @@ lean_ctor_set_usize(x_5, 4, x_1); return x_5; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__8() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__8() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = l_Lean_getExternConstArity___closed__4; -x_2 = l_Lean_getExternConstArity___closed__7; +x_1 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__4; +x_2 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__7; 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_Lean_getExternConstArity___closed__9() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__9() { _start: { 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 = lean_box(0); -x_2 = l_Lean_getExternConstArity___closed__1; -x_3 = l_Lean_getExternConstArity___closed__8; +x_2 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__1; +x_3 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__8; x_4 = l___private_Lean_Compiler_ExternAttr_0__Lean_syntaxToExternAttrData___lambda__1___closed__1; x_5 = lean_unsigned_to_nat(0u); x_6 = lean_alloc_ctor(0, 6, 0); @@ -2423,11 +2423,11 @@ lean_ctor_set(x_6, 5, x_1); return x_6; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__10() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__10() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = l_Lean_getExternConstArity___closed__3; +x_1 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__3; x_2 = lean_unsigned_to_nat(0u); x_3 = lean_alloc_ctor(0, 2, 0); lean_ctor_set(x_3, 0, x_1); @@ -2435,11 +2435,11 @@ lean_ctor_set(x_3, 1, x_2); return x_3; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__11() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__11() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = l_Lean_getExternConstArity___closed__3; +x_1 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__3; x_2 = lean_unsigned_to_nat(0u); x_3 = lean_alloc_ctor(0, 2, 0); lean_ctor_set(x_3, 0, x_1); @@ -2447,13 +2447,13 @@ lean_ctor_set(x_3, 1, x_2); return x_3; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__12() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__12() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; x_1 = lean_unsigned_to_nat(0u); -x_2 = l_Lean_getExternConstArity___closed__10; -x_3 = l_Lean_getExternConstArity___closed__11; +x_2 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__10; +x_3 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__11; x_4 = lean_alloc_ctor(0, 8, 0); lean_ctor_set(x_4, 0, x_1); lean_ctor_set(x_4, 1, x_1); @@ -2466,11 +2466,11 @@ lean_ctor_set(x_4, 7, x_2); return x_4; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__13() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__13() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = l_Lean_getExternConstArity___closed__3; +x_1 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__3; x_2 = lean_unsigned_to_nat(0u); x_3 = lean_alloc_ctor(0, 2, 0); lean_ctor_set(x_3, 0, x_1); @@ -2478,7 +2478,7 @@ lean_ctor_set(x_3, 1, x_2); return x_3; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__14() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__14() { _start: { lean_object* x_1; @@ -2486,11 +2486,11 @@ x_1 = lean_alloc_closure((void*)(l_Lean_Meta_InfoCacheKey_instHashableInfoCacheK return x_1; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__15() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__15() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = l_Lean_getExternConstArity___closed__3; +x_1 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__3; x_2 = lean_unsigned_to_nat(0u); x_3 = lean_alloc_ctor(0, 2, 0); lean_ctor_set(x_3, 0, x_1); @@ -2498,11 +2498,11 @@ lean_ctor_set(x_3, 1, x_2); return x_3; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__16() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__16() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = l_Lean_getExternConstArity___closed__3; +x_1 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__3; x_2 = lean_unsigned_to_nat(0u); x_3 = lean_alloc_ctor(0, 2, 0); lean_ctor_set(x_3, 0, x_1); @@ -2510,7 +2510,7 @@ lean_ctor_set(x_3, 1, x_2); return x_3; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__17() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__17() { _start: { lean_object* x_1; lean_object* x_2; @@ -2521,7 +2521,7 @@ lean_closure_set(x_2, 1, x_1); return x_2; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__18() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__18() { _start: { lean_object* x_1; lean_object* x_2; @@ -2532,11 +2532,11 @@ lean_closure_set(x_2, 1, x_1); return x_2; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__19() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__19() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = l_Lean_getExternConstArity___closed__3; +x_1 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__3; x_2 = lean_unsigned_to_nat(0u); x_3 = lean_alloc_ctor(0, 2, 0); lean_ctor_set(x_3, 0, x_1); @@ -2544,14 +2544,14 @@ lean_ctor_set(x_3, 1, x_2); return x_3; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__20() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__20() { _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_getExternConstArity___closed__13; -x_2 = l_Lean_getExternConstArity___closed__15; -x_3 = l_Lean_getExternConstArity___closed__16; -x_4 = l_Lean_getExternConstArity___closed__19; +x_1 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__13; +x_2 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__15; +x_3 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__16; +x_4 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__19; x_5 = lean_alloc_ctor(0, 7, 0); lean_ctor_set(x_5, 0, x_1); lean_ctor_set(x_5, 1, x_2); @@ -2563,14 +2563,14 @@ lean_ctor_set(x_5, 6, x_4); return x_5; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__21() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__21() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; lean_object* x_5; x_1 = lean_box(0); -x_2 = l_Lean_getExternConstArity___closed__12; -x_3 = l_Lean_getExternConstArity___closed__20; -x_4 = l_Lean_getExternConstArity___closed__7; +x_2 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__12; +x_3 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__20; +x_4 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__7; x_5 = lean_alloc_ctor(0, 4, 0); lean_ctor_set(x_5, 0, x_2); lean_ctor_set(x_5, 1, x_3); @@ -2579,15 +2579,15 @@ lean_ctor_set(x_5, 3, x_4); return x_5; } } -static lean_object* _init_l_Lean_getExternConstArity___closed__22() { +static lean_object* _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__22() { _start: { lean_object* x_1; -x_1 = lean_alloc_closure((void*)(l_Lean_getExternConstArity___lambda__1___boxed), 7, 0); +x_1 = lean_alloc_closure((void*)(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___lambda__1___boxed), 7, 0); return x_1; } } -LEAN_EXPORT lean_object* l_Lean_getExternConstArity(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4) { +LEAN_EXPORT lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity(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; @@ -2608,112 +2608,113 @@ x_12 = l_Lean_ParametricAttribute_getParam___rarg(x_10, x_11, x_9, x_1); if (lean_obj_tag(x_12) == 0) { lean_object* x_13; +lean_free_object(x_5); +x_13 = l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1(x_1, x_2, x_3, x_8); +if (lean_obj_tag(x_13) == 0) +{ +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; lean_object* x_21; lean_object* x_22; lean_object* x_23; lean_object* x_24; lean_object* x_25; +x_14 = lean_ctor_get(x_13, 0); +lean_inc(x_14); +x_15 = lean_ctor_get(x_13, 1); +lean_inc(x_15); +lean_dec(x_13); +x_16 = l_Lean_ConstantInfo_type(x_14); +lean_dec(x_14); +x_17 = lean_st_ref_get(x_3, x_15); +x_18 = lean_ctor_get(x_17, 1); +lean_inc(x_18); +lean_dec(x_17); +x_19 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__21; +x_20 = lean_st_mk_ref(x_19, x_18); +x_21 = lean_ctor_get(x_20, 0); +lean_inc(x_21); +x_22 = lean_ctor_get(x_20, 1); +lean_inc(x_22); +lean_dec(x_20); +x_23 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__22; +x_24 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__9; +lean_inc(x_3); +lean_inc(x_21); +x_25 = l_Lean_Meta_forallTelescopeReducing___at_Lean_Meta_getParamNames___spec__2___rarg(x_16, x_23, x_24, x_21, x_2, x_3, x_22); +if (lean_obj_tag(x_25) == 0) +{ +lean_object* x_26; lean_object* x_27; lean_object* x_28; lean_object* x_29; lean_object* x_30; uint8_t x_31; +x_26 = lean_ctor_get(x_25, 0); +lean_inc(x_26); +x_27 = lean_ctor_get(x_25, 1); +lean_inc(x_27); +lean_dec(x_25); +x_28 = lean_st_ref_get(x_3, x_27); lean_dec(x_3); -lean_dec(x_2); -lean_dec(x_1); -x_13 = lean_box(0); -lean_ctor_set(x_5, 0, x_13); -return x_5; +x_29 = lean_ctor_get(x_28, 1); +lean_inc(x_29); +lean_dec(x_28); +x_30 = lean_st_ref_get(x_21, x_29); +lean_dec(x_21); +x_31 = !lean_is_exclusive(x_30); +if (x_31 == 0) +{ +lean_object* x_32; +x_32 = lean_ctor_get(x_30, 0); +lean_dec(x_32); +lean_ctor_set(x_30, 0, x_26); +return x_30; } else { -uint8_t x_14; -x_14 = !lean_is_exclusive(x_12); -if (x_14 == 0) -{ -lean_object* x_15; lean_object* x_16; -x_15 = lean_ctor_get(x_12, 0); -x_16 = lean_ctor_get(x_15, 0); -lean_inc(x_16); -lean_dec(x_15); -if (lean_obj_tag(x_16) == 0) -{ -lean_object* x_17; -lean_free_object(x_5); -x_17 = l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1(x_1, x_2, x_3, x_8); -if (lean_obj_tag(x_17) == 0) -{ -lean_object* x_18; lean_object* x_19; lean_object* x_20; lean_object* 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; -x_18 = lean_ctor_get(x_17, 0); -lean_inc(x_18); -x_19 = lean_ctor_get(x_17, 1); -lean_inc(x_19); -lean_dec(x_17); -x_20 = l_Lean_ConstantInfo_type(x_18); -lean_dec(x_18); -x_21 = lean_st_ref_get(x_3, x_19); -x_22 = lean_ctor_get(x_21, 1); -lean_inc(x_22); -lean_dec(x_21); -x_23 = l_Lean_getExternConstArity___closed__21; -x_24 = lean_st_mk_ref(x_23, x_22); -x_25 = lean_ctor_get(x_24, 0); -lean_inc(x_25); -x_26 = lean_ctor_get(x_24, 1); -lean_inc(x_26); -lean_dec(x_24); -x_27 = l_Lean_getExternConstArity___closed__22; -x_28 = l_Lean_getExternConstArity___closed__9; -lean_inc(x_3); -lean_inc(x_25); -x_29 = l_Lean_Meta_forallTelescopeReducing___at_Lean_Meta_getParamNames___spec__2___rarg(x_20, x_27, x_28, x_25, x_2, x_3, x_26); -if (lean_obj_tag(x_29) == 0) -{ -lean_object* x_30; lean_object* x_31; lean_object* x_32; lean_object* x_33; lean_object* x_34; uint8_t x_35; -x_30 = lean_ctor_get(x_29, 0); -lean_inc(x_30); -x_31 = lean_ctor_get(x_29, 1); -lean_inc(x_31); -lean_dec(x_29); -x_32 = lean_st_ref_get(x_3, x_31); -lean_dec(x_3); -x_33 = lean_ctor_get(x_32, 1); +lean_object* x_33; lean_object* x_34; +x_33 = lean_ctor_get(x_30, 1); lean_inc(x_33); -lean_dec(x_32); -x_34 = lean_st_ref_get(x_25, x_33); -lean_dec(x_25); -x_35 = !lean_is_exclusive(x_34); -if (x_35 == 0) -{ -lean_object* x_36; -x_36 = lean_ctor_get(x_34, 0); -lean_dec(x_36); -lean_ctor_set(x_12, 0, x_30); -lean_ctor_set(x_34, 0, x_12); +lean_dec(x_30); +x_34 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_34, 0, x_26); +lean_ctor_set(x_34, 1, x_33); return x_34; } +} else { -lean_object* x_37; lean_object* x_38; -x_37 = lean_ctor_get(x_34, 1); +uint8_t x_35; +lean_dec(x_21); +lean_dec(x_3); +x_35 = !lean_is_exclusive(x_25); +if (x_35 == 0) +{ +return x_25; +} +else +{ +lean_object* x_36; lean_object* x_37; lean_object* x_38; +x_36 = lean_ctor_get(x_25, 0); +x_37 = lean_ctor_get(x_25, 1); lean_inc(x_37); -lean_dec(x_34); -lean_ctor_set(x_12, 0, x_30); -x_38 = lean_alloc_ctor(0, 2, 0); -lean_ctor_set(x_38, 0, x_12); +lean_inc(x_36); +lean_dec(x_25); +x_38 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_38, 0, x_36); lean_ctor_set(x_38, 1, x_37); return x_38; } } +} else { uint8_t x_39; -lean_dec(x_25); -lean_free_object(x_12); lean_dec(x_3); -x_39 = !lean_is_exclusive(x_29); +lean_dec(x_2); +x_39 = !lean_is_exclusive(x_13); if (x_39 == 0) { -return x_29; +return x_13; } else { lean_object* x_40; lean_object* x_41; lean_object* x_42; -x_40 = lean_ctor_get(x_29, 0); -x_41 = lean_ctor_get(x_29, 1); +x_40 = lean_ctor_get(x_13, 0); +x_41 = lean_ctor_get(x_13, 1); lean_inc(x_41); lean_inc(x_40); -lean_dec(x_29); +lean_dec(x_13); x_42 = lean_alloc_ctor(1, 2, 0); lean_ctor_set(x_42, 0, x_40); lean_ctor_set(x_42, 1, x_41); @@ -2723,437 +2724,447 @@ return x_42; } else { -uint8_t x_43; -lean_free_object(x_12); -lean_dec(x_3); -lean_dec(x_2); -x_43 = !lean_is_exclusive(x_17); -if (x_43 == 0) -{ -return x_17; -} -else -{ -lean_object* x_44; lean_object* x_45; lean_object* x_46; -x_44 = lean_ctor_get(x_17, 0); -x_45 = lean_ctor_get(x_17, 1); -lean_inc(x_45); -lean_inc(x_44); -lean_dec(x_17); -x_46 = lean_alloc_ctor(1, 2, 0); -lean_ctor_set(x_46, 0, x_44); -lean_ctor_set(x_46, 1, x_45); -return x_46; -} -} -} -else -{ -uint8_t x_47; -lean_free_object(x_12); -lean_dec(x_3); -lean_dec(x_2); -lean_dec(x_1); -x_47 = !lean_is_exclusive(x_16); -if (x_47 == 0) -{ -lean_ctor_set(x_5, 0, x_16); -return x_5; -} -else -{ -lean_object* x_48; lean_object* x_49; -x_48 = lean_ctor_get(x_16, 0); -lean_inc(x_48); -lean_dec(x_16); -x_49 = lean_alloc_ctor(1, 1, 0); -lean_ctor_set(x_49, 0, x_48); -lean_ctor_set(x_5, 0, x_49); -return x_5; -} -} -} -else -{ -lean_object* x_50; lean_object* x_51; -x_50 = lean_ctor_get(x_12, 0); -lean_inc(x_50); +lean_object* x_43; lean_object* x_44; +x_43 = lean_ctor_get(x_12, 0); +lean_inc(x_43); lean_dec(x_12); -x_51 = lean_ctor_get(x_50, 0); -lean_inc(x_51); -lean_dec(x_50); -if (lean_obj_tag(x_51) == 0) +x_44 = lean_ctor_get(x_43, 0); +lean_inc(x_44); +lean_dec(x_43); +if (lean_obj_tag(x_44) == 0) { -lean_object* x_52; +lean_object* x_45; lean_free_object(x_5); -x_52 = l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1(x_1, x_2, x_3, x_8); -if (lean_obj_tag(x_52) == 0) +x_45 = l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1(x_1, x_2, x_3, x_8); +if (lean_obj_tag(x_45) == 0) { -lean_object* x_53; lean_object* x_54; lean_object* x_55; lean_object* x_56; lean_object* x_57; lean_object* x_58; lean_object* x_59; lean_object* x_60; lean_object* x_61; lean_object* x_62; lean_object* x_63; lean_object* x_64; +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; lean_object* x_54; lean_object* x_55; lean_object* x_56; lean_object* x_57; +x_46 = lean_ctor_get(x_45, 0); +lean_inc(x_46); +x_47 = lean_ctor_get(x_45, 1); +lean_inc(x_47); +lean_dec(x_45); +x_48 = l_Lean_ConstantInfo_type(x_46); +lean_dec(x_46); +x_49 = lean_st_ref_get(x_3, x_47); +x_50 = lean_ctor_get(x_49, 1); +lean_inc(x_50); +lean_dec(x_49); +x_51 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__21; +x_52 = lean_st_mk_ref(x_51, x_50); x_53 = lean_ctor_get(x_52, 0); lean_inc(x_53); x_54 = lean_ctor_get(x_52, 1); lean_inc(x_54); lean_dec(x_52); -x_55 = l_Lean_ConstantInfo_type(x_53); -lean_dec(x_53); -x_56 = lean_st_ref_get(x_3, x_54); -x_57 = lean_ctor_get(x_56, 1); -lean_inc(x_57); -lean_dec(x_56); -x_58 = l_Lean_getExternConstArity___closed__21; -x_59 = lean_st_mk_ref(x_58, x_57); -x_60 = lean_ctor_get(x_59, 0); -lean_inc(x_60); -x_61 = lean_ctor_get(x_59, 1); -lean_inc(x_61); -lean_dec(x_59); -x_62 = l_Lean_getExternConstArity___closed__22; -x_63 = l_Lean_getExternConstArity___closed__9; +x_55 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__22; +x_56 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__9; lean_inc(x_3); -lean_inc(x_60); -x_64 = l_Lean_Meta_forallTelescopeReducing___at_Lean_Meta_getParamNames___spec__2___rarg(x_55, x_62, x_63, x_60, x_2, x_3, x_61); -if (lean_obj_tag(x_64) == 0) +lean_inc(x_53); +x_57 = l_Lean_Meta_forallTelescopeReducing___at_Lean_Meta_getParamNames___spec__2___rarg(x_48, x_55, x_56, x_53, x_2, x_3, x_54); +if (lean_obj_tag(x_57) == 0) { -lean_object* 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; -x_65 = lean_ctor_get(x_64, 0); -lean_inc(x_65); -x_66 = lean_ctor_get(x_64, 1); -lean_inc(x_66); +lean_object* x_58; lean_object* x_59; lean_object* x_60; lean_object* x_61; lean_object* x_62; uint8_t x_63; +x_58 = lean_ctor_get(x_57, 0); +lean_inc(x_58); +x_59 = lean_ctor_get(x_57, 1); +lean_inc(x_59); +lean_dec(x_57); +x_60 = lean_st_ref_get(x_3, x_59); +lean_dec(x_3); +x_61 = lean_ctor_get(x_60, 1); +lean_inc(x_61); +lean_dec(x_60); +x_62 = lean_st_ref_get(x_53, x_61); +lean_dec(x_53); +x_63 = !lean_is_exclusive(x_62); +if (x_63 == 0) +{ +lean_object* x_64; +x_64 = lean_ctor_get(x_62, 0); lean_dec(x_64); -x_67 = lean_st_ref_get(x_3, x_66); +lean_ctor_set(x_62, 0, x_58); +return x_62; +} +else +{ +lean_object* x_65; lean_object* x_66; +x_65 = lean_ctor_get(x_62, 1); +lean_inc(x_65); +lean_dec(x_62); +x_66 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_66, 0, x_58); +lean_ctor_set(x_66, 1, x_65); +return x_66; +} +} +else +{ +uint8_t x_67; +lean_dec(x_53); lean_dec(x_3); -x_68 = lean_ctor_get(x_67, 1); +x_67 = !lean_is_exclusive(x_57); +if (x_67 == 0) +{ +return x_57; +} +else +{ +lean_object* x_68; lean_object* x_69; lean_object* x_70; +x_68 = lean_ctor_get(x_57, 0); +x_69 = lean_ctor_get(x_57, 1); +lean_inc(x_69); lean_inc(x_68); -lean_dec(x_67); -x_69 = lean_st_ref_get(x_60, x_68); -lean_dec(x_60); -x_70 = lean_ctor_get(x_69, 1); -lean_inc(x_70); -if (lean_is_exclusive(x_69)) { - lean_ctor_release(x_69, 0); - lean_ctor_release(x_69, 1); - x_71 = x_69; -} else { - lean_dec_ref(x_69); - x_71 = lean_box(0); +lean_dec(x_57); +x_70 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_70, 0, x_68); +lean_ctor_set(x_70, 1, x_69); +return x_70; } -x_72 = lean_alloc_ctor(1, 1, 0); -lean_ctor_set(x_72, 0, x_65); -if (lean_is_scalar(x_71)) { - x_73 = lean_alloc_ctor(0, 2, 0); -} else { - x_73 = x_71; -} -lean_ctor_set(x_73, 0, x_72); -lean_ctor_set(x_73, 1, x_70); -return x_73; -} -else -{ -lean_object* x_74; lean_object* x_75; lean_object* x_76; lean_object* x_77; -lean_dec(x_60); -lean_dec(x_3); -x_74 = lean_ctor_get(x_64, 0); -lean_inc(x_74); -x_75 = lean_ctor_get(x_64, 1); -lean_inc(x_75); -if (lean_is_exclusive(x_64)) { - lean_ctor_release(x_64, 0); - lean_ctor_release(x_64, 1); - x_76 = x_64; -} else { - lean_dec_ref(x_64); - x_76 = lean_box(0); -} -if (lean_is_scalar(x_76)) { - x_77 = lean_alloc_ctor(1, 2, 0); -} else { - x_77 = x_76; -} -lean_ctor_set(x_77, 0, x_74); -lean_ctor_set(x_77, 1, x_75); -return x_77; } } else { -lean_object* x_78; lean_object* x_79; lean_object* x_80; lean_object* x_81; +uint8_t x_71; lean_dec(x_3); lean_dec(x_2); -x_78 = lean_ctor_get(x_52, 0); -lean_inc(x_78); -x_79 = lean_ctor_get(x_52, 1); -lean_inc(x_79); -if (lean_is_exclusive(x_52)) { - lean_ctor_release(x_52, 0); - lean_ctor_release(x_52, 1); - x_80 = x_52; -} else { - lean_dec_ref(x_52); - x_80 = lean_box(0); +x_71 = !lean_is_exclusive(x_45); +if (x_71 == 0) +{ +return x_45; } -if (lean_is_scalar(x_80)) { - x_81 = lean_alloc_ctor(1, 2, 0); -} else { - x_81 = x_80; +else +{ +lean_object* x_72; lean_object* x_73; lean_object* x_74; +x_72 = lean_ctor_get(x_45, 0); +x_73 = lean_ctor_get(x_45, 1); +lean_inc(x_73); +lean_inc(x_72); +lean_dec(x_45); +x_74 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_74, 0, x_72); +lean_ctor_set(x_74, 1, x_73); +return x_74; } -lean_ctor_set(x_81, 0, x_78); -lean_ctor_set(x_81, 1, x_79); -return x_81; } } else { -lean_object* x_82; lean_object* x_83; lean_object* x_84; +lean_object* x_75; lean_dec(x_3); lean_dec(x_2); lean_dec(x_1); -x_82 = lean_ctor_get(x_51, 0); -lean_inc(x_82); -if (lean_is_exclusive(x_51)) { - lean_ctor_release(x_51, 0); - x_83 = x_51; -} else { - lean_dec_ref(x_51); - x_83 = lean_box(0); -} -if (lean_is_scalar(x_83)) { - x_84 = lean_alloc_ctor(1, 1, 0); -} else { - x_84 = x_83; -} -lean_ctor_set(x_84, 0, x_82); -lean_ctor_set(x_5, 0, x_84); +x_75 = lean_ctor_get(x_44, 0); +lean_inc(x_75); +lean_dec(x_44); +lean_ctor_set(x_5, 0, x_75); return x_5; } } } +else +{ +lean_object* x_76; lean_object* x_77; lean_object* x_78; lean_object* x_79; lean_object* x_80; lean_object* x_81; +x_76 = lean_ctor_get(x_5, 0); +x_77 = lean_ctor_get(x_5, 1); +lean_inc(x_77); +lean_inc(x_76); +lean_dec(x_5); +x_78 = lean_ctor_get(x_76, 0); +lean_inc(x_78); +lean_dec(x_76); +x_79 = l_Lean_instInhabitedExternAttrData; +x_80 = l_Lean_externAttr; +lean_inc(x_1); +x_81 = l_Lean_ParametricAttribute_getParam___rarg(x_79, x_80, x_78, x_1); +if (lean_obj_tag(x_81) == 0) +{ +lean_object* x_82; +x_82 = l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1(x_1, x_2, x_3, x_77); +if (lean_obj_tag(x_82) == 0) +{ +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; +x_83 = lean_ctor_get(x_82, 0); +lean_inc(x_83); +x_84 = lean_ctor_get(x_82, 1); +lean_inc(x_84); +lean_dec(x_82); +x_85 = l_Lean_ConstantInfo_type(x_83); +lean_dec(x_83); +x_86 = lean_st_ref_get(x_3, x_84); +x_87 = lean_ctor_get(x_86, 1); +lean_inc(x_87); +lean_dec(x_86); +x_88 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__21; +x_89 = lean_st_mk_ref(x_88, x_87); +x_90 = lean_ctor_get(x_89, 0); +lean_inc(x_90); +x_91 = lean_ctor_get(x_89, 1); +lean_inc(x_91); +lean_dec(x_89); +x_92 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__22; +x_93 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__9; +lean_inc(x_3); +lean_inc(x_90); +x_94 = l_Lean_Meta_forallTelescopeReducing___at_Lean_Meta_getParamNames___spec__2___rarg(x_85, x_92, x_93, x_90, x_2, x_3, x_91); +if (lean_obj_tag(x_94) == 0) +{ +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; +x_95 = lean_ctor_get(x_94, 0); +lean_inc(x_95); +x_96 = lean_ctor_get(x_94, 1); +lean_inc(x_96); +lean_dec(x_94); +x_97 = lean_st_ref_get(x_3, x_96); +lean_dec(x_3); +x_98 = lean_ctor_get(x_97, 1); +lean_inc(x_98); +lean_dec(x_97); +x_99 = lean_st_ref_get(x_90, x_98); +lean_dec(x_90); +x_100 = lean_ctor_get(x_99, 1); +lean_inc(x_100); +if (lean_is_exclusive(x_99)) { + lean_ctor_release(x_99, 0); + lean_ctor_release(x_99, 1); + x_101 = x_99; +} else { + lean_dec_ref(x_99); + x_101 = lean_box(0); +} +if (lean_is_scalar(x_101)) { + x_102 = lean_alloc_ctor(0, 2, 0); +} else { + x_102 = x_101; +} +lean_ctor_set(x_102, 0, x_95); +lean_ctor_set(x_102, 1, x_100); +return x_102; } else { -lean_object* x_85; lean_object* x_86; lean_object* x_87; lean_object* x_88; lean_object* x_89; lean_object* x_90; -x_85 = lean_ctor_get(x_5, 0); -x_86 = lean_ctor_get(x_5, 1); -lean_inc(x_86); -lean_inc(x_85); -lean_dec(x_5); -x_87 = lean_ctor_get(x_85, 0); -lean_inc(x_87); -lean_dec(x_85); -x_88 = l_Lean_instInhabitedExternAttrData; -x_89 = l_Lean_externAttr; -lean_inc(x_1); -x_90 = l_Lean_ParametricAttribute_getParam___rarg(x_88, x_89, x_87, x_1); -if (lean_obj_tag(x_90) == 0) +lean_object* x_103; lean_object* x_104; lean_object* x_105; lean_object* x_106; +lean_dec(x_90); +lean_dec(x_3); +x_103 = lean_ctor_get(x_94, 0); +lean_inc(x_103); +x_104 = lean_ctor_get(x_94, 1); +lean_inc(x_104); +if (lean_is_exclusive(x_94)) { + lean_ctor_release(x_94, 0); + lean_ctor_release(x_94, 1); + x_105 = x_94; +} else { + lean_dec_ref(x_94); + x_105 = lean_box(0); +} +if (lean_is_scalar(x_105)) { + x_106 = lean_alloc_ctor(1, 2, 0); +} else { + x_106 = x_105; +} +lean_ctor_set(x_106, 0, x_103); +lean_ctor_set(x_106, 1, x_104); +return x_106; +} +} +else { -lean_object* x_91; lean_object* x_92; +lean_object* x_107; lean_object* x_108; lean_object* x_109; lean_object* x_110; lean_dec(x_3); lean_dec(x_2); -lean_dec(x_1); -x_91 = lean_box(0); -x_92 = lean_alloc_ctor(0, 2, 0); -lean_ctor_set(x_92, 0, x_91); -lean_ctor_set(x_92, 1, x_86); -return x_92; +x_107 = lean_ctor_get(x_82, 0); +lean_inc(x_107); +x_108 = lean_ctor_get(x_82, 1); +lean_inc(x_108); +if (lean_is_exclusive(x_82)) { + lean_ctor_release(x_82, 0); + lean_ctor_release(x_82, 1); + x_109 = x_82; +} else { + lean_dec_ref(x_82); + x_109 = lean_box(0); +} +if (lean_is_scalar(x_109)) { + x_110 = lean_alloc_ctor(1, 2, 0); +} else { + x_110 = x_109; +} +lean_ctor_set(x_110, 0, x_107); +lean_ctor_set(x_110, 1, x_108); +return x_110; +} } else { -lean_object* x_93; lean_object* x_94; lean_object* x_95; -x_93 = lean_ctor_get(x_90, 0); -lean_inc(x_93); -if (lean_is_exclusive(x_90)) { - lean_ctor_release(x_90, 0); - x_94 = x_90; -} else { - lean_dec_ref(x_90); - x_94 = lean_box(0); -} -x_95 = lean_ctor_get(x_93, 0); -lean_inc(x_95); -lean_dec(x_93); -if (lean_obj_tag(x_95) == 0) -{ -lean_object* x_96; -x_96 = l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1(x_1, x_2, x_3, x_86); -if (lean_obj_tag(x_96) == 0) -{ -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; lean_object* x_106; lean_object* x_107; lean_object* x_108; -x_97 = lean_ctor_get(x_96, 0); -lean_inc(x_97); -x_98 = lean_ctor_get(x_96, 1); -lean_inc(x_98); -lean_dec(x_96); -x_99 = l_Lean_ConstantInfo_type(x_97); -lean_dec(x_97); -x_100 = lean_st_ref_get(x_3, x_98); -x_101 = lean_ctor_get(x_100, 1); -lean_inc(x_101); -lean_dec(x_100); -x_102 = l_Lean_getExternConstArity___closed__21; -x_103 = lean_st_mk_ref(x_102, x_101); -x_104 = lean_ctor_get(x_103, 0); -lean_inc(x_104); -x_105 = lean_ctor_get(x_103, 1); -lean_inc(x_105); -lean_dec(x_103); -x_106 = l_Lean_getExternConstArity___closed__22; -x_107 = l_Lean_getExternConstArity___closed__9; -lean_inc(x_3); -lean_inc(x_104); -x_108 = l_Lean_Meta_forallTelescopeReducing___at_Lean_Meta_getParamNames___spec__2___rarg(x_99, x_106, x_107, x_104, x_2, x_3, x_105); -if (lean_obj_tag(x_108) == 0) -{ -lean_object* x_109; lean_object* x_110; lean_object* x_111; lean_object* x_112; lean_object* x_113; lean_object* x_114; lean_object* x_115; lean_object* x_116; lean_object* x_117; -x_109 = lean_ctor_get(x_108, 0); -lean_inc(x_109); -x_110 = lean_ctor_get(x_108, 1); -lean_inc(x_110); -lean_dec(x_108); -x_111 = lean_st_ref_get(x_3, x_110); -lean_dec(x_3); -x_112 = lean_ctor_get(x_111, 1); +lean_object* x_111; lean_object* x_112; +x_111 = lean_ctor_get(x_81, 0); +lean_inc(x_111); +lean_dec(x_81); +x_112 = lean_ctor_get(x_111, 0); lean_inc(x_112); lean_dec(x_111); -x_113 = lean_st_ref_get(x_104, x_112); -lean_dec(x_104); -x_114 = lean_ctor_get(x_113, 1); +if (lean_obj_tag(x_112) == 0) +{ +lean_object* x_113; +x_113 = l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1(x_1, x_2, x_3, x_77); +if (lean_obj_tag(x_113) == 0) +{ +lean_object* x_114; lean_object* x_115; lean_object* x_116; lean_object* x_117; lean_object* x_118; lean_object* x_119; lean_object* x_120; lean_object* x_121; lean_object* x_122; lean_object* x_123; lean_object* x_124; lean_object* x_125; +x_114 = lean_ctor_get(x_113, 0); lean_inc(x_114); +x_115 = lean_ctor_get(x_113, 1); +lean_inc(x_115); +lean_dec(x_113); +x_116 = l_Lean_ConstantInfo_type(x_114); +lean_dec(x_114); +x_117 = lean_st_ref_get(x_3, x_115); +x_118 = lean_ctor_get(x_117, 1); +lean_inc(x_118); +lean_dec(x_117); +x_119 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__21; +x_120 = lean_st_mk_ref(x_119, x_118); +x_121 = lean_ctor_get(x_120, 0); +lean_inc(x_121); +x_122 = lean_ctor_get(x_120, 1); +lean_inc(x_122); +lean_dec(x_120); +x_123 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__22; +x_124 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__9; +lean_inc(x_3); +lean_inc(x_121); +x_125 = l_Lean_Meta_forallTelescopeReducing___at_Lean_Meta_getParamNames___spec__2___rarg(x_116, x_123, x_124, x_121, x_2, x_3, x_122); +if (lean_obj_tag(x_125) == 0) +{ +lean_object* x_126; lean_object* x_127; lean_object* x_128; lean_object* x_129; lean_object* x_130; lean_object* x_131; lean_object* x_132; lean_object* x_133; +x_126 = lean_ctor_get(x_125, 0); +lean_inc(x_126); +x_127 = lean_ctor_get(x_125, 1); +lean_inc(x_127); +lean_dec(x_125); +x_128 = lean_st_ref_get(x_3, x_127); +lean_dec(x_3); +x_129 = lean_ctor_get(x_128, 1); +lean_inc(x_129); +lean_dec(x_128); +x_130 = lean_st_ref_get(x_121, x_129); +lean_dec(x_121); +x_131 = lean_ctor_get(x_130, 1); +lean_inc(x_131); +if (lean_is_exclusive(x_130)) { + lean_ctor_release(x_130, 0); + lean_ctor_release(x_130, 1); + x_132 = x_130; +} else { + lean_dec_ref(x_130); + x_132 = lean_box(0); +} +if (lean_is_scalar(x_132)) { + x_133 = lean_alloc_ctor(0, 2, 0); +} else { + x_133 = x_132; +} +lean_ctor_set(x_133, 0, x_126); +lean_ctor_set(x_133, 1, x_131); +return x_133; +} +else +{ +lean_object* x_134; lean_object* x_135; lean_object* x_136; lean_object* x_137; +lean_dec(x_121); +lean_dec(x_3); +x_134 = lean_ctor_get(x_125, 0); +lean_inc(x_134); +x_135 = lean_ctor_get(x_125, 1); +lean_inc(x_135); +if (lean_is_exclusive(x_125)) { + lean_ctor_release(x_125, 0); + lean_ctor_release(x_125, 1); + x_136 = x_125; +} else { + lean_dec_ref(x_125); + x_136 = lean_box(0); +} +if (lean_is_scalar(x_136)) { + x_137 = lean_alloc_ctor(1, 2, 0); +} else { + x_137 = x_136; +} +lean_ctor_set(x_137, 0, x_134); +lean_ctor_set(x_137, 1, x_135); +return x_137; +} +} +else +{ +lean_object* x_138; lean_object* x_139; lean_object* x_140; lean_object* x_141; +lean_dec(x_3); +lean_dec(x_2); +x_138 = lean_ctor_get(x_113, 0); +lean_inc(x_138); +x_139 = lean_ctor_get(x_113, 1); +lean_inc(x_139); if (lean_is_exclusive(x_113)) { lean_ctor_release(x_113, 0); lean_ctor_release(x_113, 1); - x_115 = x_113; + x_140 = x_113; } else { lean_dec_ref(x_113); - x_115 = lean_box(0); + x_140 = lean_box(0); } -if (lean_is_scalar(x_94)) { - x_116 = lean_alloc_ctor(1, 1, 0); +if (lean_is_scalar(x_140)) { + x_141 = lean_alloc_ctor(1, 2, 0); } else { - x_116 = x_94; + x_141 = x_140; } -lean_ctor_set(x_116, 0, x_109); -if (lean_is_scalar(x_115)) { - x_117 = lean_alloc_ctor(0, 2, 0); -} else { - x_117 = x_115; -} -lean_ctor_set(x_117, 0, x_116); -lean_ctor_set(x_117, 1, x_114); -return x_117; -} -else -{ -lean_object* x_118; lean_object* x_119; lean_object* x_120; lean_object* x_121; -lean_dec(x_104); -lean_dec(x_94); -lean_dec(x_3); -x_118 = lean_ctor_get(x_108, 0); -lean_inc(x_118); -x_119 = lean_ctor_get(x_108, 1); -lean_inc(x_119); -if (lean_is_exclusive(x_108)) { - lean_ctor_release(x_108, 0); - lean_ctor_release(x_108, 1); - x_120 = x_108; -} else { - lean_dec_ref(x_108); - x_120 = lean_box(0); -} -if (lean_is_scalar(x_120)) { - x_121 = lean_alloc_ctor(1, 2, 0); -} else { - x_121 = x_120; -} -lean_ctor_set(x_121, 0, x_118); -lean_ctor_set(x_121, 1, x_119); -return x_121; +lean_ctor_set(x_141, 0, x_138); +lean_ctor_set(x_141, 1, x_139); +return x_141; } } else { -lean_object* x_122; lean_object* x_123; lean_object* x_124; lean_object* x_125; -lean_dec(x_94); -lean_dec(x_3); -lean_dec(x_2); -x_122 = lean_ctor_get(x_96, 0); -lean_inc(x_122); -x_123 = lean_ctor_get(x_96, 1); -lean_inc(x_123); -if (lean_is_exclusive(x_96)) { - lean_ctor_release(x_96, 0); - lean_ctor_release(x_96, 1); - x_124 = x_96; -} else { - lean_dec_ref(x_96); - x_124 = lean_box(0); -} -if (lean_is_scalar(x_124)) { - x_125 = lean_alloc_ctor(1, 2, 0); -} else { - x_125 = x_124; -} -lean_ctor_set(x_125, 0, x_122); -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_object* x_129; -lean_dec(x_94); +lean_object* x_142; lean_object* x_143; lean_dec(x_3); lean_dec(x_2); lean_dec(x_1); -x_126 = lean_ctor_get(x_95, 0); -lean_inc(x_126); -if (lean_is_exclusive(x_95)) { - lean_ctor_release(x_95, 0); - x_127 = x_95; -} else { - lean_dec_ref(x_95); - x_127 = lean_box(0); -} -if (lean_is_scalar(x_127)) { - x_128 = lean_alloc_ctor(1, 1, 0); -} else { - x_128 = x_127; -} -lean_ctor_set(x_128, 0, 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_86); -return x_129; +x_142 = lean_ctor_get(x_112, 0); +lean_inc(x_142); +lean_dec(x_112); +x_143 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_143, 0, x_142); +lean_ctor_set(x_143, 1, x_77); +return x_143; } } } } } -LEAN_EXPORT lean_object* l_Lean_throwError___at_Lean_getExternConstArity___spec__2___boxed(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4) { +LEAN_EXPORT lean_object* l_Lean_throwError___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__2___boxed(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4) { _start: { lean_object* x_5; -x_5 = l_Lean_throwError___at_Lean_getExternConstArity___spec__2(x_1, x_2, x_3, x_4); +x_5 = l_Lean_throwError___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__2(x_1, x_2, x_3, x_4); lean_dec(x_3); lean_dec(x_2); return x_5; } } -LEAN_EXPORT lean_object* l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___boxed(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4) { +LEAN_EXPORT lean_object* l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___boxed(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4) { _start: { lean_object* x_5; -x_5 = l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1(x_1, x_2, x_3, x_4); +x_5 = l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1(x_1, x_2, x_3, x_4); lean_dec(x_3); lean_dec(x_2); return x_5; } } -LEAN_EXPORT lean_object* l_Lean_getExternConstArity___lambda__1___boxed(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_EXPORT lean_object* l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___lambda__1___boxed(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) { _start: { lean_object* x_8; -x_8 = l_Lean_getExternConstArity___lambda__1(x_1, x_2, x_3, x_4, x_5, x_6, x_7); +x_8 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___lambda__1(x_1, x_2, x_3, x_4, x_5, x_6, x_7); lean_dec(x_6); lean_dec(x_5); lean_dec(x_4); @@ -3217,7 +3228,7 @@ _start: { uint8_t x_1; lean_object* x_2; lean_object* x_3; x_1 = 1; -x_2 = l_Lean_getExternConstArity___closed__7; +x_2 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__7; x_3 = lean_alloc_ctor(0, 1, 1); lean_ctor_set(x_3, 0, x_2); lean_ctor_set_uint8(x_3, sizeof(void*)*1, x_1); @@ -3264,7 +3275,7 @@ x_20 = lean_ctor_get(x_18, 1); lean_inc(x_20); lean_dec(x_18); lean_inc(x_19); -x_21 = l_Lean_getExternConstArity(x_2, x_17, x_19, x_20); +x_21 = l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity(x_2, x_17, x_19, x_20); if (lean_obj_tag(x_21) == 0) { lean_object* x_22; lean_object* x_23; lean_object* x_24; uint8_t x_25; @@ -3278,120 +3289,124 @@ lean_dec(x_19); x_25 = !lean_is_exclusive(x_24); if (x_25 == 0) { -lean_object* x_26; +lean_object* x_26; lean_object* x_27; x_26 = lean_ctor_get(x_24, 0); lean_dec(x_26); -lean_ctor_set(x_24, 0, x_22); +x_27 = lean_alloc_ctor(1, 1, 0); +lean_ctor_set(x_27, 0, x_22); +lean_ctor_set(x_24, 0, x_27); return x_24; } else { -lean_object* x_27; lean_object* x_28; -x_27 = lean_ctor_get(x_24, 1); -lean_inc(x_27); +lean_object* x_28; lean_object* x_29; lean_object* x_30; +x_28 = lean_ctor_get(x_24, 1); +lean_inc(x_28); lean_dec(x_24); -x_28 = lean_alloc_ctor(0, 2, 0); -lean_ctor_set(x_28, 0, x_22); -lean_ctor_set(x_28, 1, x_27); -return x_28; +x_29 = lean_alloc_ctor(1, 1, 0); +lean_ctor_set(x_29, 0, x_22); +x_30 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_30, 0, x_29); +lean_ctor_set(x_30, 1, x_28); +return x_30; } } else { -lean_object* x_29; +lean_object* x_31; lean_dec(x_19); -x_29 = lean_ctor_get(x_21, 0); -lean_inc(x_29); -if (lean_obj_tag(x_29) == 0) -{ -lean_object* x_30; lean_object* x_31; lean_object* x_32; -x_30 = lean_ctor_get(x_21, 1); -lean_inc(x_30); -lean_dec(x_21); -x_31 = lean_ctor_get(x_29, 1); +x_31 = lean_ctor_get(x_21, 0); lean_inc(x_31); -lean_dec(x_29); -x_32 = l_Lean_MessageData_toString(x_31, x_30); -if (lean_obj_tag(x_32) == 0) +if (lean_obj_tag(x_31) == 0) { -uint8_t x_33; -x_33 = !lean_is_exclusive(x_32); -if (x_33 == 0) +lean_object* x_32; lean_object* x_33; lean_object* x_34; +x_32 = lean_ctor_get(x_21, 1); +lean_inc(x_32); +lean_dec(x_21); +x_33 = lean_ctor_get(x_31, 1); +lean_inc(x_33); +lean_dec(x_31); +x_34 = l_Lean_MessageData_toString(x_33, x_32); +if (lean_obj_tag(x_34) == 0) { -lean_object* x_34; lean_object* x_35; -x_34 = lean_ctor_get(x_32, 0); -lean_dec(x_34); -x_35 = lean_box(0); -lean_ctor_set(x_32, 0, x_35); -return x_32; -} -else +uint8_t x_35; +x_35 = !lean_is_exclusive(x_34); +if (x_35 == 0) { -lean_object* x_36; lean_object* x_37; lean_object* x_38; -x_36 = lean_ctor_get(x_32, 1); -lean_inc(x_36); -lean_dec(x_32); +lean_object* x_36; lean_object* x_37; +x_36 = lean_ctor_get(x_34, 0); +lean_dec(x_36); x_37 = lean_box(0); -x_38 = lean_alloc_ctor(0, 2, 0); -lean_ctor_set(x_38, 0, x_37); -lean_ctor_set(x_38, 1, x_36); -return x_38; +lean_ctor_set(x_34, 0, x_37); +return x_34; +} +else +{ +lean_object* x_38; lean_object* x_39; lean_object* x_40; +x_38 = lean_ctor_get(x_34, 1); +lean_inc(x_38); +lean_dec(x_34); +x_39 = lean_box(0); +x_40 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_40, 0, x_39); +lean_ctor_set(x_40, 1, x_38); +return x_40; } } else { -uint8_t x_39; -x_39 = !lean_is_exclusive(x_32); -if (x_39 == 0) +uint8_t x_41; +x_41 = !lean_is_exclusive(x_34); +if (x_41 == 0) { -lean_object* x_40; lean_object* x_41; -x_40 = lean_ctor_get(x_32, 0); -lean_dec(x_40); -x_41 = lean_box(0); -lean_ctor_set_tag(x_32, 0); -lean_ctor_set(x_32, 0, x_41); -return x_32; -} -else -{ -lean_object* x_42; lean_object* x_43; lean_object* x_44; -x_42 = lean_ctor_get(x_32, 1); -lean_inc(x_42); -lean_dec(x_32); +lean_object* x_42; lean_object* x_43; +x_42 = lean_ctor_get(x_34, 0); +lean_dec(x_42); x_43 = lean_box(0); -x_44 = lean_alloc_ctor(0, 2, 0); -lean_ctor_set(x_44, 0, x_43); -lean_ctor_set(x_44, 1, x_42); -return x_44; +lean_ctor_set_tag(x_34, 0); +lean_ctor_set(x_34, 0, x_43); +return x_34; +} +else +{ +lean_object* x_44; lean_object* x_45; lean_object* x_46; +x_44 = lean_ctor_get(x_34, 1); +lean_inc(x_44); +lean_dec(x_34); +x_45 = lean_box(0); +x_46 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_46, 0, x_45); +lean_ctor_set(x_46, 1, x_44); +return x_46; } } } else { -uint8_t x_45; -lean_dec(x_29); -x_45 = !lean_is_exclusive(x_21); -if (x_45 == 0) +uint8_t x_47; +lean_dec(x_31); +x_47 = !lean_is_exclusive(x_21); +if (x_47 == 0) { -lean_object* x_46; lean_object* x_47; -x_46 = lean_ctor_get(x_21, 0); -lean_dec(x_46); -x_47 = lean_box(0); +lean_object* x_48; lean_object* x_49; +x_48 = lean_ctor_get(x_21, 0); +lean_dec(x_48); +x_49 = lean_box(0); lean_ctor_set_tag(x_21, 0); -lean_ctor_set(x_21, 0, x_47); +lean_ctor_set(x_21, 0, x_49); return x_21; } else { -lean_object* x_48; lean_object* x_49; lean_object* x_50; -x_48 = lean_ctor_get(x_21, 1); -lean_inc(x_48); +lean_object* x_50; lean_object* x_51; lean_object* x_52; +x_50 = lean_ctor_get(x_21, 1); +lean_inc(x_50); lean_dec(x_21); -x_49 = lean_box(0); -x_50 = lean_alloc_ctor(0, 2, 0); -lean_ctor_set(x_50, 0, x_49); -lean_ctor_set(x_50, 1, x_48); -return x_50; +x_51 = lean_box(0); +x_52 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_52, 0, x_51); +lean_ctor_set(x_52, 1, x_50); +return x_52; } } } @@ -3512,58 +3527,58 @@ l_Lean_mkSimpleFnCall___closed__2 = _init_l_Lean_mkSimpleFnCall___closed__2(); lean_mark_persistent(l_Lean_mkSimpleFnCall___closed__2); l_Lean_mkSimpleFnCall___closed__3 = _init_l_Lean_mkSimpleFnCall___closed__3(); lean_mark_persistent(l_Lean_mkSimpleFnCall___closed__3); -l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__1 = _init_l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__1(); -lean_mark_persistent(l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__1); -l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__2 = _init_l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__2(); -lean_mark_persistent(l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__2); -l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__3 = _init_l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__3(); -lean_mark_persistent(l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__3); -l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__4 = _init_l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__4(); -lean_mark_persistent(l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1___closed__4); -l_Lean_getExternConstArity___closed__1 = _init_l_Lean_getExternConstArity___closed__1(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__1); -l_Lean_getExternConstArity___closed__2 = _init_l_Lean_getExternConstArity___closed__2(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__2); -l_Lean_getExternConstArity___closed__3 = _init_l_Lean_getExternConstArity___closed__3(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__3); -l_Lean_getExternConstArity___closed__4 = _init_l_Lean_getExternConstArity___closed__4(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__4); -l_Lean_getExternConstArity___closed__5 = _init_l_Lean_getExternConstArity___closed__5(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__5); -l_Lean_getExternConstArity___closed__6 = _init_l_Lean_getExternConstArity___closed__6(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__6); -l_Lean_getExternConstArity___closed__7 = _init_l_Lean_getExternConstArity___closed__7(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__7); -l_Lean_getExternConstArity___closed__8 = _init_l_Lean_getExternConstArity___closed__8(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__8); -l_Lean_getExternConstArity___closed__9 = _init_l_Lean_getExternConstArity___closed__9(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__9); -l_Lean_getExternConstArity___closed__10 = _init_l_Lean_getExternConstArity___closed__10(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__10); -l_Lean_getExternConstArity___closed__11 = _init_l_Lean_getExternConstArity___closed__11(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__11); -l_Lean_getExternConstArity___closed__12 = _init_l_Lean_getExternConstArity___closed__12(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__12); -l_Lean_getExternConstArity___closed__13 = _init_l_Lean_getExternConstArity___closed__13(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__13); -l_Lean_getExternConstArity___closed__14 = _init_l_Lean_getExternConstArity___closed__14(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__14); -l_Lean_getExternConstArity___closed__15 = _init_l_Lean_getExternConstArity___closed__15(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__15); -l_Lean_getExternConstArity___closed__16 = _init_l_Lean_getExternConstArity___closed__16(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__16); -l_Lean_getExternConstArity___closed__17 = _init_l_Lean_getExternConstArity___closed__17(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__17); -l_Lean_getExternConstArity___closed__18 = _init_l_Lean_getExternConstArity___closed__18(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__18); -l_Lean_getExternConstArity___closed__19 = _init_l_Lean_getExternConstArity___closed__19(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__19); -l_Lean_getExternConstArity___closed__20 = _init_l_Lean_getExternConstArity___closed__20(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__20); -l_Lean_getExternConstArity___closed__21 = _init_l_Lean_getExternConstArity___closed__21(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__21); -l_Lean_getExternConstArity___closed__22 = _init_l_Lean_getExternConstArity___closed__22(); -lean_mark_persistent(l_Lean_getExternConstArity___closed__22); +l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__1 = _init_l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__1(); +lean_mark_persistent(l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__1); +l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__2 = _init_l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__2(); +lean_mark_persistent(l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__2); +l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__3 = _init_l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__3(); +lean_mark_persistent(l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__3); +l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__4 = _init_l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__4(); +lean_mark_persistent(l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1___closed__4); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__1 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__1(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__1); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__2 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__2(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__2); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__3 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__3(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__3); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__4 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__4(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__4); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__5 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__5(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__5); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__6 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__6(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__6); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__7 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__7(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__7); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__8 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__8(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__8); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__9 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__9(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__9); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__10 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__10(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__10); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__11 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__11(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__11); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__12 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__12(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__12); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__13 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__13(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__13); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__14 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__14(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__14); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__15 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__15(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__15); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__16 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__16(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__16); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__17 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__17(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__17); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__18 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__18(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__18); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__19 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__19(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__19); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__20 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__20(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__20); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__21 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__21(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__21); +l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__22 = _init_l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__22(); +lean_mark_persistent(l___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___closed__22); l_Lean_getExternConstArityExport___closed__1 = _init_l_Lean_getExternConstArityExport___closed__1(); lean_mark_persistent(l_Lean_getExternConstArityExport___closed__1); l_Lean_getExternConstArityExport___closed__2 = _init_l_Lean_getExternConstArityExport___closed__2(); diff --git a/stage0/stdlib/Lean/Compiler/IR/Basic.c b/stage0/stdlib/Lean/Compiler/IR/Basic.c index 04bb0080ce..14ef14cc1b 100644 --- a/stage0/stdlib/Lean/Compiler/IR/Basic.c +++ b/stage0/stdlib/Lean/Compiler/IR/Basic.c @@ -40,6 +40,7 @@ static lean_object* l_Lean_IR_instToStringJoinPointId___closed__1; LEAN_EXPORT lean_object* l_Array_mapMUnsafe_map___at_Lean_IR_mmodifyJPs___spec__1___rarg___lambda__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT uint8_t l_Lean_IR_Index_lt(lean_object*, lean_object*); LEAN_EXPORT lean_object* lean_ir_mk_vdecl(lean_object*, lean_object*, lean_object*, lean_object*); +LEAN_EXPORT lean_object* lean_ir_mk_dummy_extern_decl(lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_IR_LocalContext_eraseJoinPointDecl(lean_object*, lean_object*); lean_object* lean_array_uset(lean_object*, size_t, lean_object*); LEAN_EXPORT lean_object* l_Lean_IR_LitVal_beq___boxed(lean_object*, lean_object*); @@ -3435,6 +3436,21 @@ lean_ctor_set(x_5, 3, x_4); return x_5; } } +LEAN_EXPORT lean_object* lean_ir_mk_dummy_extern_decl(lean_object* x_1, lean_object* x_2, lean_object* x_3) { +_start: +{ +lean_object* x_4; lean_object* x_5; lean_object* x_6; +x_4 = lean_box(0); +x_5 = lean_box(13); +x_6 = lean_alloc_ctor(0, 5, 0); +lean_ctor_set(x_6, 0, x_1); +lean_ctor_set(x_6, 1, x_2); +lean_ctor_set(x_6, 2, x_3); +lean_ctor_set(x_6, 3, x_5); +lean_ctor_set(x_6, 4, x_4); +return x_6; +} +} static lean_object* _init_l_Lean_IR_instInhabitedIndexSet() { _start: { diff --git a/stage0/stdlib/Lean/Elab/DefView.c b/stage0/stdlib/Lean/Elab/DefView.c index e7c07eb01c..34060f7bbc 100644 --- a/stage0/stdlib/Lean/Elab/DefView.c +++ b/stage0/stdlib/Lean/Elab/DefView.c @@ -64,7 +64,6 @@ LEAN_EXPORT lean_object* l_Lean_throwError___at_Lean_Elab_Command_mkDefViewOfIns LEAN_EXPORT lean_object* l_Lean_Elab_Command_MkInstanceName_collect___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_Elab_Command_MkInstanceName_mkFreshInstanceName___rarg___boxed(lean_object*, lean_object*); static lean_object* l___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanceName_kindReplacements___closed__2; -lean_object* lean_string_utf8_byte_size(lean_object*); static lean_object* l_Lean_Elab_Command_mkDefViewOfInstance___closed__4; LEAN_EXPORT lean_object* l_Lean_Elab_Command_mkDefViewOfConstant(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_Elab_Command_mkDefViewOfDef(lean_object*, lean_object*); @@ -112,7 +111,6 @@ LEAN_EXPORT lean_object* l_Lean_Elab_throwUnsupportedSyntax___at_Lean_Elab_Comma lean_object* l_Lean_replaceRef(lean_object*, lean_object*); lean_object* l_String_capitalize(lean_object*); static lean_object* l_Lean_Elab_Command_mkDefViewOfConstant___closed__4; -static lean_object* l_Lean_Elab_Command_mkDefViewOfInstance___closed__11; LEAN_EXPORT lean_object* l_Lean_Elab_DefKind_toCtorIdx(uint8_t); static lean_object* l_Lean_Elab_Command_mkDefViewOfConstant___closed__8; uint8_t l_Lean_Name_quickCmp(lean_object*, lean_object*); @@ -164,7 +162,6 @@ LEAN_EXPORT lean_object* l_Lean_Elab_throwUnsupportedSyntax___at_Lean_Elab_Comma LEAN_EXPORT uint8_t l_Lean_Elab_DefKind_isTheorem(uint8_t); LEAN_EXPORT lean_object* l_Lean_throwErrorAt___at_Lean_Elab_Command_MkInstanceName_main___spec__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_Elab_throwUnsupportedSyntax___at_Lean_Elab_Command_mkDefViewOfInstance___spec__4___rarg(lean_object*); -lean_object* l_Lean_addMacroScope(lean_object*, lean_object*, lean_object*); static lean_object* l___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanceName_kindReplacements___closed__36; static lean_object* l_Lean_Elab_Command_MkInstanceName_isFirst___closed__1; static lean_object* l___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanceName_kindReplacements___closed__35; @@ -182,11 +179,10 @@ LEAN_EXPORT lean_object* l_Lean_Elab_Command_MkInstanceName_isFirst(lean_object* lean_object* l_Lean_Elab_addMacroStack___at_Lean_Elab_Command_instAddErrorMessageContextCommandElabM___spec__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Elab_Command_getCurrMacroScope(lean_object*, lean_object*, lean_object*); uint8_t l_Std_RBNode_isRed___rarg(lean_object*); -static lean_object* l_Lean_Elab_Command_mkDefViewOfConstant___closed__12; LEAN_EXPORT lean_object* l_Lean_Elab_DefKind_noConfusion___rarg___lambda__1(lean_object*); LEAN_EXPORT lean_object* l_Lean_throwErrorAt___at_Lean_Elab_Command_mkDefViewOfInstance___spec__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Syntax_getKind(lean_object*); -LEAN_EXPORT lean_object* l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520_(lean_object*); +LEAN_EXPORT lean_object* l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514_(lean_object*); static lean_object* l___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanceName_kindReplacements___closed__20; static lean_object* l___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanceName_kindReplacements___closed__10; static lean_object* l___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanceName_kindReplacements___closed__32; @@ -196,10 +192,8 @@ LEAN_EXPORT lean_object* l_Lean_Elab_throwUnsupportedSyntax___at_Lean_Elab_Comma static lean_object* l_Lean_Elab_Command_mkDefViewOfExample___closed__2; lean_object* l_Lean_Elab_Command_getRef(lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Elab_expandDeclSig(lean_object*); -static lean_object* l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__4; lean_object* lean_st_ref_set(lean_object*, lean_object*, lean_object*); static lean_object* l_Lean_Elab_Command_mkDefViewOfInstance___closed__2; -static lean_object* l_Lean_Elab_Command_mkDefViewOfConstant___closed__11; LEAN_EXPORT lean_object* l_Lean_throwError___at_Lean_Elab_Command_mkDefView___spec__1(lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_resolveGlobalName___at_Lean_Elab_Command_MkInstanceName_collect___spec__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); uint8_t l_Lean_Syntax_isNone(lean_object*); @@ -210,6 +204,7 @@ static lean_object* l_Lean_Elab_Command_mkDefViewOfInstance___closed__9; static lean_object* l___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanceName_kindReplacements___closed__29; LEAN_EXPORT lean_object* l_Lean_Elab_liftMacroM___at_Lean_Elab_Command_MkInstanceName_main___spec__1___lambda__2(lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_Elab_Command_mkDefViewOfAbbrev(lean_object*, lean_object*); +static lean_object* l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__4; lean_object* l_Lean_Elab_expandOptNamedPrio___boxed(lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_Elab_Command_MkInstanceName_mkFreshInstanceName(lean_object*); static lean_object* l_Lean_Elab_Command_isDefLike___closed__3; @@ -228,11 +223,14 @@ static lean_object* l___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanc LEAN_EXPORT lean_object* l_Lean_Elab_DefKind_noConfusion(lean_object*); static lean_object* l_Lean_Elab_Command_mkDefView___closed__1; static lean_object* l___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanceName_kindReplacements___closed__28; +static lean_object* l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__1; uint8_t l_List_isEmpty___rarg(lean_object*); static lean_object* l___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanceName_kindReplacements___closed__18; +static lean_object* l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__3; lean_object* l_Lean_Elab_Command_getScope___rarg(lean_object*, lean_object*); static lean_object* l___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanceName_kindReplacements___closed__5; static lean_object* l___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanceName_kindReplacements___closed__3; +static lean_object* l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__2; static lean_object* l___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanceName_kindReplacements___closed__15; LEAN_EXPORT lean_object* l_Lean_Elab_Command_MkInstanceName_mkFreshInstanceName___boxed(lean_object*); LEAN_EXPORT lean_object* l_Std_RBNode_ins___at___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanceName_kindReplacements___spec__3(lean_object*, lean_object*, lean_object*); @@ -247,19 +245,16 @@ static lean_object* l_Lean_Elab_Command_mkDefViewOfInstance___closed__3; LEAN_EXPORT lean_object* l_Lean_Elab_Command_mkDefViewOfInstance(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); static lean_object* l_Lean_Elab_Command_isDefLike___closed__7; static lean_object* l_Lean_Elab_Command_mkDefViewOfConstant___closed__7; -static lean_object* l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__2; LEAN_EXPORT lean_object* l_Lean_Elab_Command_MkInstanceName_main(lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT uint8_t l___private_Lean_Elab_DefView_0__Lean_Elab_beqDefKind____x40_Lean_Elab_DefView___hyg_14_(uint8_t, uint8_t); static lean_object* l___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanceName_kindReplacements___closed__22; LEAN_EXPORT lean_object* l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Command_mkDefViewOfConstant___spec__1(lean_object*, lean_object*, lean_object*); static lean_object* l___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanceName_kindReplacements___closed__33; static lean_object* l___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanceName_kindReplacements___closed__14; -static lean_object* l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__3; lean_object* l_Lean_Elab_mkUnusedBaseName(lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Elab_getBetterRef(lean_object*, lean_object*); uint8_t lean_string_dec_eq(lean_object*, lean_object*); lean_object* l_Lean_Syntax_mkLit(lean_object*, lean_object*, lean_object*); -static lean_object* l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__1; static lean_object* l_Lean_Elab_Command_mkDefViewOfExample___closed__1; LEAN_EXPORT lean_object* l_Lean_Elab_DefKind_toCtorIdx(uint8_t x_1) { _start: @@ -5180,80 +5175,68 @@ static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__1() _start: { lean_object* x_1; -x_1 = lean_mk_string("arbitrary"); +x_1 = lean_mk_string("arbitraryOrOfNonempty"); return x_1; } } static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__2() { _start: { -lean_object* x_1; lean_object* x_2; -x_1 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__1; -x_2 = lean_string_utf8_byte_size(x_1); -return x_2; -} -} -static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__3() { -_start: -{ -lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; -x_1 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__1; -x_2 = lean_unsigned_to_nat(0u); -x_3 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__2; -x_4 = lean_alloc_ctor(0, 3, 0); -lean_ctor_set(x_4, 0, x_1); -lean_ctor_set(x_4, 1, x_2); -lean_ctor_set(x_4, 2, x_3); -return x_4; -} -} -static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__4() { -_start: -{ lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = lean_box(0); +x_1 = l___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanceName_kindReplacements___closed__6; x_2 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__1; x_3 = lean_name_mk_string(x_1, x_2); return x_3; } } +static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__3() { +_start: +{ +lean_object* x_1; +x_1 = lean_mk_string("arbitrary_or_ofNonempty%"); +return x_1; +} +} +static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__4() { +_start: +{ +lean_object* x_1; lean_object* x_2; +x_1 = lean_unsigned_to_nat(1u); +x_2 = lean_mk_empty_array_with_capacity(x_1); +return x_2; +} +} static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__5() { _start: { -lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = lean_box(0); -x_2 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__4; -x_3 = lean_alloc_ctor(0, 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_Command_mkDefViewOfConstant___closed__6() { -_start: -{ -lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = lean_box(0); -x_2 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__5; -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_Command_mkDefViewOfConstant___closed__7() { -_start: -{ lean_object* x_1; x_1 = lean_mk_string("Command"); return x_1; } } -static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__8() { +static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__6() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; x_1 = l___private_Lean_Elab_DefView_0__Lean_Elab_Command_MkInstanceName_kindReplacements___closed__4; +x_2 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__5; +x_3 = lean_name_mk_string(x_1, x_2); +return x_3; +} +} +static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__7() { +_start: +{ +lean_object* x_1; +x_1 = lean_mk_string("declValSimple"); +return x_1; +} +} +static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__8() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__6; x_2 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__7; x_3 = lean_name_mk_string(x_1, x_2); return x_3; @@ -5263,29 +5246,11 @@ static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__9() _start: { lean_object* x_1; -x_1 = lean_mk_string("declValSimple"); -return x_1; -} -} -static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__10() { -_start: -{ -lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__8; -x_2 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__9; -x_3 = lean_name_mk_string(x_1, x_2); -return x_3; -} -} -static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__11() { -_start: -{ -lean_object* x_1; x_1 = lean_mk_string(":="); return x_1; } } -static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__12() { +static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__10() { _start: { lean_object* x_1; lean_object* x_2; @@ -5313,7 +5278,7 @@ x_13 = l_Lean_Syntax_getOptional_x3f(x_12); lean_dec(x_12); if (lean_obj_tag(x_13) == 0) { -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; lean_object* 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_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; lean_object* 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; x_14 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Command_mkDefViewOfConstant___spec__1(x_3, x_4, x_5); x_15 = lean_ctor_get(x_14, 0); lean_inc(x_15); @@ -5321,53 +5286,51 @@ x_16 = lean_ctor_get(x_14, 1); lean_inc(x_16); lean_dec(x_14); x_17 = l_Lean_Elab_Command_getCurrMacroScope(x_3, x_4, x_16); -x_18 = lean_ctor_get(x_17, 0); +x_18 = lean_ctor_get(x_17, 1); lean_inc(x_18); -x_19 = lean_ctor_get(x_17, 1); -lean_inc(x_19); lean_dec(x_17); -x_20 = l_Lean_Elab_Command_getMainModule___rarg(x_4, x_19); -x_21 = lean_ctor_get(x_20, 0); -lean_inc(x_21); -x_22 = lean_ctor_get(x_20, 1); -lean_inc(x_22); -lean_dec(x_20); +x_19 = l_Lean_Elab_Command_getMainModule___rarg(x_4, x_18); +x_20 = lean_ctor_get(x_19, 1); +lean_inc(x_20); +lean_dec(x_19); +x_21 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__3; +x_22 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_22, 0, x_15); +lean_ctor_set(x_22, 1, x_21); x_23 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__4; -x_24 = l_Lean_addMacroScope(x_21, x_23, x_18); -x_25 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__3; -x_26 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__6; -x_27 = lean_alloc_ctor(3, 4, 0); -lean_ctor_set(x_27, 0, x_15); -lean_ctor_set(x_27, 1, x_25); +x_24 = lean_array_push(x_23, x_22); +x_25 = lean_box(2); +x_26 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__2; +x_27 = lean_alloc_ctor(1, 3, 0); +lean_ctor_set(x_27, 0, x_25); +lean_ctor_set(x_27, 1, x_26); lean_ctor_set(x_27, 2, x_24); -lean_ctor_set(x_27, 3, x_26); -x_28 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__11; +x_28 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__9; lean_inc(x_2); x_29 = l_Lean_mkAtomFrom(x_2, x_28); -x_30 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__12; +x_30 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__10; x_31 = lean_array_push(x_30, x_29); x_32 = lean_array_push(x_31, x_27); -x_33 = lean_box(2); -x_34 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__10; -x_35 = lean_alloc_ctor(1, 3, 0); -lean_ctor_set(x_35, 0, x_33); -lean_ctor_set(x_35, 1, x_34); -lean_ctor_set(x_35, 2, x_32); -x_36 = l_Lean_Elab_Command_mkDefViewOfConstant___lambda__1(x_2, x_10, x_1, x_9, x_35, x_3, x_4, x_22); +x_33 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__8; +x_34 = lean_alloc_ctor(1, 3, 0); +lean_ctor_set(x_34, 0, x_25); +lean_ctor_set(x_34, 1, x_33); +lean_ctor_set(x_34, 2, x_32); +x_35 = l_Lean_Elab_Command_mkDefViewOfConstant___lambda__1(x_2, x_10, x_1, x_9, x_34, x_3, x_4, x_20); lean_dec(x_4); lean_dec(x_3); -return x_36; +return x_35; } else { -lean_object* x_37; lean_object* x_38; -x_37 = lean_ctor_get(x_13, 0); -lean_inc(x_37); +lean_object* x_36; lean_object* x_37; +x_36 = lean_ctor_get(x_13, 0); +lean_inc(x_36); lean_dec(x_13); -x_38 = l_Lean_Elab_Command_mkDefViewOfConstant___lambda__1(x_2, x_10, x_1, x_9, x_37, x_3, x_4, x_5); +x_37 = l_Lean_Elab_Command_mkDefViewOfConstant___lambda__1(x_2, x_10, x_1, x_9, x_36, x_3, x_4, x_5); lean_dec(x_4); lean_dec(x_3); -return x_38; +return x_37; } } } @@ -6229,15 +6192,6 @@ return x_3; static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfInstance___closed__7() { _start: { -lean_object* x_1; lean_object* x_2; -x_1 = lean_unsigned_to_nat(1u); -x_2 = lean_mk_empty_array_with_capacity(x_1); -return x_2; -} -} -static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfInstance___closed__8() { -_start: -{ lean_object* x_1; lean_object* x_2; lean_object* x_3; x_1 = lean_box(0); x_2 = l_Lean_Elab_Command_mkDefViewOfInstance___closed__3; @@ -6245,7 +6199,7 @@ x_3 = lean_name_mk_string(x_1, x_2); return x_3; } } -static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfInstance___closed__9() { +static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfInstance___closed__8() { _start: { lean_object* x_1; @@ -6253,17 +6207,17 @@ x_1 = lean_mk_string("declId"); return x_1; } } -static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfInstance___closed__10() { +static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfInstance___closed__9() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__8; -x_2 = l_Lean_Elab_Command_mkDefViewOfInstance___closed__9; +x_1 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__6; +x_2 = l_Lean_Elab_Command_mkDefViewOfInstance___closed__8; x_3 = lean_name_mk_string(x_1, x_2); return x_3; } } -static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfInstance___closed__11() { +static lean_object* _init_l_Lean_Elab_Command_mkDefViewOfInstance___closed__10() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; @@ -6333,14 +6287,14 @@ x_27 = l_Nat_repr(x_16); x_28 = l_Lean_numLitKind; x_29 = lean_box(2); x_30 = l_Lean_Syntax_mkLit(x_28, x_27, x_29); -x_31 = l_Lean_Elab_Command_mkDefViewOfInstance___closed__7; +x_31 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__4; x_32 = lean_array_push(x_31, x_30); x_33 = l_Lean_Elab_Command_mkDefViewOfInstance___closed__6; x_34 = lean_alloc_ctor(1, 3, 0); lean_ctor_set(x_34, 0, x_29); lean_ctor_set(x_34, 1, x_33); lean_ctor_set(x_34, 2, x_32); -x_35 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__12; +x_35 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__10; x_36 = lean_array_push(x_35, x_26); x_37 = lean_array_push(x_36, x_34); x_38 = l_Lean_Elab_Command_mkDefViewOfInstance___closed__4; @@ -6357,7 +6311,7 @@ lean_inc(x_43); x_44 = lean_ctor_get(x_42, 1); lean_inc(x_44); lean_dec(x_42); -x_45 = l_Lean_Elab_Command_mkDefViewOfInstance___closed__8; +x_45 = l_Lean_Elab_Command_mkDefViewOfInstance___closed__7; x_46 = lean_alloc_ctor(0, 2, 1); lean_ctor_set(x_46, 0, x_45); lean_ctor_set(x_46, 1, x_39); @@ -6387,9 +6341,9 @@ lean_dec(x_52); lean_inc(x_2); x_55 = l_Lean_mkIdentFrom(x_2, x_53); x_56 = lean_array_push(x_35, x_55); -x_57 = l_Lean_Elab_Command_mkDefViewOfInstance___closed__11; +x_57 = l_Lean_Elab_Command_mkDefViewOfInstance___closed__10; x_58 = lean_array_push(x_56, x_57); -x_59 = l_Lean_Elab_Command_mkDefViewOfInstance___closed__10; +x_59 = l_Lean_Elab_Command_mkDefViewOfInstance___closed__9; x_60 = lean_alloc_ctor(1, 3, 0); lean_ctor_set(x_60, 0, x_29); lean_ctor_set(x_60, 1, x_59); @@ -6578,12 +6532,12 @@ lean_dec(x_5); x_8 = l_Lean_Elab_Command_mkDefViewOfExample___closed__2; lean_inc(x_2); x_9 = l_Lean_mkIdentFrom(x_2, x_8); -x_10 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__12; +x_10 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__10; x_11 = lean_array_push(x_10, x_9); -x_12 = l_Lean_Elab_Command_mkDefViewOfInstance___closed__11; +x_12 = l_Lean_Elab_Command_mkDefViewOfInstance___closed__10; x_13 = lean_array_push(x_11, x_12); x_14 = lean_box(2); -x_15 = l_Lean_Elab_Command_mkDefViewOfInstance___closed__10; +x_15 = l_Lean_Elab_Command_mkDefViewOfInstance___closed__9; x_16 = lean_alloc_ctor(1, 3, 0); lean_ctor_set(x_16, 0, x_14); lean_ctor_set(x_16, 1, x_15); @@ -6618,7 +6572,7 @@ static lean_object* _init_l_Lean_Elab_Command_isDefLike___closed__2() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__8; +x_1 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__6; x_2 = l_Lean_Elab_Command_isDefLike___closed__1; x_3 = lean_name_mk_string(x_1, x_2); return x_3; @@ -6636,7 +6590,7 @@ static lean_object* _init_l_Lean_Elab_Command_isDefLike___closed__4() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__8; +x_1 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__6; x_2 = l_Lean_Elab_Command_isDefLike___closed__3; x_3 = lean_name_mk_string(x_1, x_2); return x_3; @@ -6654,7 +6608,7 @@ static lean_object* _init_l_Lean_Elab_Command_isDefLike___closed__6() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__8; +x_1 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__6; x_2 = l_Lean_Elab_Command_isDefLike___closed__5; x_3 = lean_name_mk_string(x_1, x_2); return x_3; @@ -6672,7 +6626,7 @@ static lean_object* _init_l_Lean_Elab_Command_isDefLike___closed__8() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__8; +x_1 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__6; x_2 = l_Lean_Elab_Command_isDefLike___closed__7; x_3 = lean_name_mk_string(x_1, x_2); return x_3; @@ -6682,7 +6636,7 @@ static lean_object* _init_l_Lean_Elab_Command_isDefLike___closed__9() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__8; +x_1 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__6; x_2 = l_Lean_Elab_Command_mkDefViewOfInstance___closed__3; x_3 = lean_name_mk_string(x_1, x_2); return x_3; @@ -6700,7 +6654,7 @@ static lean_object* _init_l_Lean_Elab_Command_isDefLike___closed__11() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__8; +x_1 = l_Lean_Elab_Command_mkDefViewOfConstant___closed__6; x_2 = l_Lean_Elab_Command_isDefLike___closed__10; x_3 = lean_name_mk_string(x_1, x_2); return x_3; @@ -6983,7 +6937,7 @@ lean_dec(x_3); return x_5; } } -static lean_object* _init_l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__1() { +static lean_object* _init_l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__1() { _start: { lean_object* x_1; @@ -6991,17 +6945,17 @@ x_1 = lean_mk_string("Elab"); return x_1; } } -static lean_object* _init_l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__2() { +static lean_object* _init_l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__2() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; x_1 = lean_box(0); -x_2 = l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__1; +x_2 = l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__1; x_3 = lean_name_mk_string(x_1, x_2); return x_3; } } -static lean_object* _init_l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__3() { +static lean_object* _init_l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__3() { _start: { lean_object* x_1; @@ -7009,21 +6963,21 @@ x_1 = lean_mk_string("definition"); return x_1; } } -static lean_object* _init_l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__4() { +static lean_object* _init_l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__4() { _start: { lean_object* x_1; lean_object* x_2; lean_object* x_3; -x_1 = l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__2; -x_2 = l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__3; +x_1 = l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__2; +x_2 = l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__3; x_3 = lean_name_mk_string(x_1, x_2); return x_3; } } -LEAN_EXPORT lean_object* l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520_(lean_object* x_1) { +LEAN_EXPORT lean_object* l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514_(lean_object* x_1) { _start: { lean_object* x_2; lean_object* x_3; -x_2 = l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__4; +x_2 = l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__4; x_3 = l_Lean_registerTraceClass(x_2, x_1); return x_3; } @@ -7202,10 +7156,6 @@ l_Lean_Elab_Command_mkDefViewOfConstant___closed__9 = _init_l_Lean_Elab_Command_ lean_mark_persistent(l_Lean_Elab_Command_mkDefViewOfConstant___closed__9); l_Lean_Elab_Command_mkDefViewOfConstant___closed__10 = _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__10(); lean_mark_persistent(l_Lean_Elab_Command_mkDefViewOfConstant___closed__10); -l_Lean_Elab_Command_mkDefViewOfConstant___closed__11 = _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__11(); -lean_mark_persistent(l_Lean_Elab_Command_mkDefViewOfConstant___closed__11); -l_Lean_Elab_Command_mkDefViewOfConstant___closed__12 = _init_l_Lean_Elab_Command_mkDefViewOfConstant___closed__12(); -lean_mark_persistent(l_Lean_Elab_Command_mkDefViewOfConstant___closed__12); l_Lean_Elab_Command_mkDefViewOfInstance___closed__1 = _init_l_Lean_Elab_Command_mkDefViewOfInstance___closed__1(); lean_mark_persistent(l_Lean_Elab_Command_mkDefViewOfInstance___closed__1); l_Lean_Elab_Command_mkDefViewOfInstance___closed__2 = _init_l_Lean_Elab_Command_mkDefViewOfInstance___closed__2(); @@ -7226,8 +7176,6 @@ l_Lean_Elab_Command_mkDefViewOfInstance___closed__9 = _init_l_Lean_Elab_Command_ lean_mark_persistent(l_Lean_Elab_Command_mkDefViewOfInstance___closed__9); l_Lean_Elab_Command_mkDefViewOfInstance___closed__10 = _init_l_Lean_Elab_Command_mkDefViewOfInstance___closed__10(); lean_mark_persistent(l_Lean_Elab_Command_mkDefViewOfInstance___closed__10); -l_Lean_Elab_Command_mkDefViewOfInstance___closed__11 = _init_l_Lean_Elab_Command_mkDefViewOfInstance___closed__11(); -lean_mark_persistent(l_Lean_Elab_Command_mkDefViewOfInstance___closed__11); l_Lean_Elab_Command_mkDefViewOfExample___closed__1 = _init_l_Lean_Elab_Command_mkDefViewOfExample___closed__1(); lean_mark_persistent(l_Lean_Elab_Command_mkDefViewOfExample___closed__1); l_Lean_Elab_Command_mkDefViewOfExample___closed__2 = _init_l_Lean_Elab_Command_mkDefViewOfExample___closed__2(); @@ -7258,15 +7206,15 @@ l_Lean_Elab_Command_mkDefView___closed__1 = _init_l_Lean_Elab_Command_mkDefView_ lean_mark_persistent(l_Lean_Elab_Command_mkDefView___closed__1); l_Lean_Elab_Command_mkDefView___closed__2 = _init_l_Lean_Elab_Command_mkDefView___closed__2(); lean_mark_persistent(l_Lean_Elab_Command_mkDefView___closed__2); -l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__1 = _init_l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__1(); -lean_mark_persistent(l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__1); -l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__2 = _init_l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__2(); -lean_mark_persistent(l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__2); -l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__3 = _init_l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__3(); -lean_mark_persistent(l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__3); -l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__4 = _init_l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__4(); -lean_mark_persistent(l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520____closed__4); -res = l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1520_(lean_io_mk_world()); +l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__1 = _init_l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__1(); +lean_mark_persistent(l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__1); +l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__2 = _init_l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__2(); +lean_mark_persistent(l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__2); +l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__3 = _init_l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__3(); +lean_mark_persistent(l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__3); +l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__4 = _init_l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__4(); +lean_mark_persistent(l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514____closed__4); +res = l_Lean_Elab_Command_initFn____x40_Lean_Elab_DefView___hyg_1514_(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)); diff --git a/stage0/stdlib/Lean/Elab/Extra.c b/stage0/stdlib/Lean/Elab/Extra.c index d6d4a6122b..6d4125bbc0 100644 --- a/stage0/stdlib/Lean/Elab/Extra.c +++ b/stage0/stdlib/Lean/Elab/Extra.c @@ -18,6 +18,7 @@ static lean_object* l___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_toTree_g LEAN_EXPORT lean_object* l_Array_forInUnsafe_loop___at_Lean_Elab_Term_BinOp_elabBinCalc___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_EXPORT lean_object* l_Lean_Elab_Term_elabBinRelCore___lambda__3(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_BinOp_elabBinCalc___spec__1___closed__1; +static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__3; static lean_object* l_Array_forInUnsafe_loop___at_Lean_Elab_Term_BinOp_elabBinCalc___spec__1___closed__2; lean_object* l_Lean_Elab_throwUnsupportedSyntax___at_Lean_Elab_Term_elabForall___spec__1___rarg(lean_object*); LEAN_EXPORT lean_object* l_Lean_Elab_Term_elabBinRelCore_toBoolIfNecessary___lambda__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); @@ -32,6 +33,7 @@ lean_object* l_Lean_registerTraceClass(lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_Elab_Term_elabForIn(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_elabForIn_getMonad___closed__4; static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabBinOp_declRange___closed__5; +static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__5; lean_object* l_Lean_stringToMessageData(lean_object*); static lean_object* l___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_toTree_go___closed__5; lean_object* lean_mk_empty_array_with_capacity(lean_object*); @@ -64,6 +66,7 @@ LEAN_EXPORT lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabBinOp_declRange static lean_object* l___regBuiltin_Lean_Elab_Term_elabBinRel___closed__14; static lean_object* l_Lean_Elab_Term_elabForIn___closed__16; static lean_object* l___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_applyCoe_go___closed__2; +LEAN_EXPORT lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty(lean_object*); static lean_object* l___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_toTree_go___closed__1; static lean_object* l_Array_forInUnsafe_loop___at_Lean_Elab_Term_BinOp_elabBinCalc___spec__1___closed__9; static lean_object* l___regBuiltin_Lean_Elab_Term_elabBinRelNoProp_declRange___closed__3; @@ -85,6 +88,7 @@ LEAN_EXPORT lean_object* l_Lean_Elab_Term_elabBinRelCore_toBoolIfNecessary___lam static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabBinCalc_declRange___closed__2; lean_object* l_Lean_Expr_appFn_x21(lean_object*); static lean_object* l_Lean_Elab_Term_elabForIn_getMonad___closed__5; +lean_object* l_Lean_Meta_mkOfNonempty(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabBinOpLazy_declRange___closed__5; static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabBinOp_declRange___closed__2; lean_object* lean_array_push(lean_object*, lean_object*); @@ -93,6 +97,7 @@ static lean_object* l___regBuiltin_Lean_Elab_Term_elabBinRel___closed__3; lean_object* l_Lean_Elab_liftMacroM___at___private_Lean_Elab_Term_0__Lean_Elab_Term_elabTermAux___spec__8(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); static lean_object* l___regBuiltin_Lean_Elab_Term_elabBinRelNoProp_declRange___closed__1; static lean_object* l___regBuiltin_Lean_Elab_Term_elabBinRel___closed__12; +static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__3; static lean_object* l___regBuiltin_Lean_Elab_Term_elabForIn___closed__1; static lean_object* l___regBuiltin_Lean_Elab_Term_elabBinRelNoProp_declRange___closed__2; LEAN_EXPORT lean_object* l_Array_forInUnsafe_loop___at_Lean_Elab_Term_BinOp_elabBinCalc___spec__1___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*); @@ -110,8 +115,11 @@ LEAN_EXPORT lean_object* l___regBuiltin_Lean_Elab_Term_elabBinRel_declRange(lean lean_object* l_Lean_KeyedDeclsAttribute_addBuiltin___rarg(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Elab_Term_getMainModule___rarg(lean_object*, lean_object*); uint8_t lean_usize_dec_lt(size_t, size_t); +static lean_object* l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___rarg___closed__1; static lean_object* l_Lean_Elab_Term_BinOp_elabBinOp___closed__17; +static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__7; static lean_object* l___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_applyCoe_go___lambda__2___closed__5; +static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__5; static lean_object* l_Lean_Elab_Term_BinOp_elabBinOp___closed__1; extern lean_object* l_Lean_levelZero; lean_object* lean_nat_add(lean_object*, lean_object*); @@ -119,6 +127,7 @@ LEAN_EXPORT lean_object* l_Lean_Elab_Term_BinOp_elabBinOp___lambda__2(lean_objec static lean_object* l_Lean_Elab_Term_elabForIn___closed__19; lean_object* l_Lean_Elab_Term_ensureHasType(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_BinOp_elabBinCalc___spec__1___closed__5; +static lean_object* l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___rarg___closed__2; static lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Term_BinOp_elabBinCalc___spec__2___closed__6; static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabBinOpLazy_declRange___closed__2; static lean_object* l___regBuiltin_Lean_Elab_Term_elabBinRel___closed__5; @@ -180,6 +189,7 @@ LEAN_EXPORT lean_object* l_Lean_addTrace___at___private_Lean_Elab_Extra_0__Lean_ static lean_object* l_Lean_throwUnknownConstant___at_Lean_Elab_Term_elabBinRelCore___spec__1___closed__3; lean_object* l_Lean_Elab_Term_mkCoe(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___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_analyze_go___lambda__1(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_BinOp_elabArbitraryOrNonempty___closed__4; lean_object* l_Lean_replaceRef(lean_object*, lean_object*); lean_object* lean_array_get(lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_Meta_withNewMCtxDepth___at___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_analyze_go___spec__1(lean_object*); @@ -190,7 +200,9 @@ LEAN_EXPORT lean_object* l_Lean_Elab_Term_BinOp_elabBinCalc(lean_object*, lean_o lean_object* l_Lean_Elab_Term_elabAppArgs(lean_object*, lean_object*, lean_object*, lean_object*, uint8_t, uint8_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_relation_x3f___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); static lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Term_BinOp_elabBinCalc___spec__2___closed__11; +LEAN_EXPORT lean_object* l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___rarg(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); static lean_object* l_Lean_Elab_Term_BinOp_elabBinOp___closed__20; +lean_object* l_Lean_Meta_mkArbitrary(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); static lean_object* l___regBuiltin_Lean_Elab_Term_elabBinRelNoProp___closed__1; static lean_object* l_Lean_Elab_Term_elabBinRelCore___lambda__2___closed__1; static lean_object* l___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_applyCoe_go___closed__4; @@ -200,6 +212,7 @@ LEAN_EXPORT lean_object* l_Lean_Elab_Term_elabBinRelCore___lambda__2___boxed(lea static lean_object* l___regBuiltin_Lean_Elab_Term_elabBinRel___closed__10; static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabBinCalc___closed__2; lean_object* lean_st_mk_ref(lean_object*, lean_object*); +LEAN_EXPORT lean_object* l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___rarg___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Syntax_getId(lean_object*); lean_object* l_Lean_Elab_addMacroStack___at_Lean_Elab_Term_instAddErrorMessageContextTermElabM___spec__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Elab_Term_synthesizeSyntheticMVars_loop(uint8_t, uint8_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); @@ -213,6 +226,7 @@ lean_object* l_Lean_Elab_Term_getCurrMacroScope(lean_object*, lean_object*, lean static lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Term_BinOp_elabBinCalc___spec__2___closed__13; static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabBinOpLazy_declRange___closed__1; uint8_t l_Lean_Environment_contains(lean_object*, lean_object*); +static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__6; static lean_object* l___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_analyze_go___closed__6; static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabBinCalc_declRange___closed__5; LEAN_EXPORT lean_object* l_Lean_throwError___at___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_toTree_processOp___spec__2___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); @@ -232,7 +246,7 @@ static lean_object* l_Lean_throwUnknownConstant___at_Lean_Elab_Term_elabBinRelCo static lean_object* l_Lean_Elab_Term_elabBinRelCore_toBoolIfNecessary___closed__5; extern lean_object* l_Lean_instInhabitedSyntax; LEAN_EXPORT lean_object* l___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_toExpr(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); -LEAN_EXPORT lean_object* l_Lean_Elab_Term_BinOp_initFn____x40_Lean_Elab_Extra___hyg_4917_(lean_object*); +LEAN_EXPORT lean_object* l_Lean_Elab_Term_BinOp_initFn____x40_Lean_Elab_Extra___hyg_4993_(lean_object*); LEAN_EXPORT lean_object* l_Lean_Elab_Term_elabBinRel(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_elabBinRelCore___lambda__2___closed__5; LEAN_EXPORT uint8_t l___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_isUnknow(lean_object*); @@ -244,6 +258,8 @@ size_t lean_usize_of_nat(lean_object*); LEAN_EXPORT lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabBinCalc(lean_object*); lean_object* l_Lean_addTrace___at___private_Lean_Elab_Term_0__Lean_Elab_Term_postponeElabTerm___spec__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_addMacroScope(lean_object*, lean_object*, lean_object*); +LEAN_EXPORT lean_object* l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___boxed(lean_object*); +static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__4; static lean_object* l_Lean_Elab_Term_elabForIn___closed__9; LEAN_EXPORT lean_object* l___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_mkOp(lean_object*, 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_BinOp_elabBinOp___closed__4; @@ -264,6 +280,7 @@ static lean_object* l_Lean_Elab_Term_elabForIn___closed__8; static lean_object* l___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_analyze_go___closed__5; static lean_object* l___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_toTree_go___closed__3; lean_object* l_panic___at___private_Lean_Elab_SyntheticMVars_0__Lean_Elab_Term_reportStuckSyntheticMVars___spec__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__2; LEAN_EXPORT lean_object* l_Lean_Elab_Term_elabBinRelCore___lambda__1___boxed(lean_object*, 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_elabForIn___closed__3; static lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Term_BinOp_elabBinCalc___spec__2___closed__4; @@ -273,6 +290,7 @@ static lean_object* l_Lean_Elab_Term_BinOp_elabBinOp___closed__16; static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabBinCalc___closed__3; lean_object* l_Lean_Meta_trySynthInstance(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Expr_getAppNumArgsAux(lean_object*, lean_object*); +static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__1; lean_object* l___private_Lean_Util_Trace_0__Lean_checkTraceOptionM___at___private_Lean_Elab_Term_0__Lean_Elab_Term_postponeElabTerm___spec__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_analyze_go(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); static lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Term_BinOp_elabBinCalc___spec__2___closed__9; @@ -310,6 +328,7 @@ lean_object* l___private_Lean_Elab_SyntheticMVars_0__Lean_Elab_Term_withSynthesi static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabBinCalc___closed__5; static lean_object* l_Lean_Elab_Term_elabForIn___closed__21; static lean_object* l_Lean_Elab_Term_elabBinRelCore_toBoolIfNecessary___closed__4; +LEAN_EXPORT lean_object* l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty(lean_object*); static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabBinOpLazy___closed__1; LEAN_EXPORT lean_object* l_Lean_Elab_Term_elabForIn___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___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_analyze___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); @@ -323,6 +342,7 @@ lean_object* l_Lean_Meta_getLevel(lean_object*, lean_object*, lean_object*, lean static lean_object* l_Lean_Elab_Term_elabForIn___closed__3; static lean_object* l_Lean_Elab_Term_elabBinRelCore_toBoolIfNecessary___closed__2; LEAN_EXPORT lean_object* l_Lean_throwError___at___private_Lean_Elab_Extra_0__Lean_Elab_Term_BinOp_toTree_processOp___spec__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__2; lean_object* l_Lean_Elab_Term_elabType(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* lean_st_ref_set(lean_object*, lean_object*, lean_object*); static lean_object* l_Lean_Elab_Term_elabBinRelCore___closed__1; @@ -360,6 +380,7 @@ LEAN_EXPORT lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabBinCalc_declRan lean_object* l_Lean_Syntax_getArg(lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_Elab_Term_elabBinRelCore_toBoolIfNecessary___lambda__1(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_elabBinRel___closed__2; +static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__1; static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabBinOp_declRange___closed__1; static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabBinCalc_declRange___closed__7; static lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabBinOp___closed__2; @@ -374,6 +395,7 @@ static lean_object* l_Lean_Elab_Term_BinOp_elabBinOp___closed__5; static lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Term_BinOp_elabBinCalc___spec__2___closed__12; static lean_object* l_Lean_Elab_Term_BinOp_elabBinOp___closed__3; static lean_object* l_Lean_Elab_Term_BinOp_elabBinOp___closed__15; +LEAN_EXPORT lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange(lean_object*); static lean_object* l_Lean_Elab_Term_BinOp_elabBinOp___closed__14; LEAN_EXPORT lean_object* l_Lean_Elab_Term_elabBinRelCore___lambda__1(lean_object*, 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_elabForIn_declRange___closed__1; @@ -15344,7 +15366,328 @@ x_4 = l_Lean_addBuiltinDeclarationRanges(x_2, x_3, x_1); return x_4; } } -LEAN_EXPORT lean_object* l_Lean_Elab_Term_BinOp_initFn____x40_Lean_Elab_Extra___hyg_4917_(lean_object* x_1) { +static lean_object* _init_l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___rarg___closed__1() { +_start: +{ +lean_object* x_1; +x_1 = lean_mk_string("invalid 'arbitrary_or_ofNonempty%', expected type is not known"); +return x_1; +} +} +static lean_object* _init_l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___rarg___closed__2() { +_start: +{ +lean_object* x_1; lean_object* x_2; +x_1 = l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___rarg___closed__1; +x_2 = l_Lean_stringToMessageData(x_1); +return x_2; +} +} +LEAN_EXPORT lean_object* l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___rarg(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) { +_start: +{ +lean_object* x_9; +lean_inc(x_5); +lean_inc(x_2); +lean_inc(x_1); +x_9 = l_Lean_Elab_Term_tryPostponeIfNoneOrMVar(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8); +if (lean_obj_tag(x_9) == 0) +{ +if (lean_obj_tag(x_1) == 0) +{ +lean_object* x_10; lean_object* x_11; lean_object* x_12; +x_10 = lean_ctor_get(x_9, 1); +lean_inc(x_10); +lean_dec(x_9); +x_11 = l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___rarg___closed__2; +x_12 = l_Lean_throwError___at_Lean_Elab_Term_synthesizeInst___spec__1(x_11, x_2, x_3, x_4, x_5, x_6, x_7, x_10); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +return x_12; +} +else +{ +lean_object* x_13; lean_object* x_14; lean_object* x_15; +lean_dec(x_2); +x_13 = lean_ctor_get(x_9, 1); +lean_inc(x_13); +lean_dec(x_9); +x_14 = lean_ctor_get(x_1, 0); +lean_inc(x_14); +lean_dec(x_1); +lean_inc(x_7); +lean_inc(x_6); +lean_inc(x_5); +lean_inc(x_4); +lean_inc(x_14); +x_15 = l_Lean_Meta_mkArbitrary(x_14, x_4, x_5, x_6, x_7, x_13); +if (lean_obj_tag(x_15) == 0) +{ +lean_dec(x_14); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +return x_15; +} +else +{ +lean_object* x_16; lean_object* x_17; lean_object* x_18; +x_16 = lean_ctor_get(x_15, 0); +lean_inc(x_16); +x_17 = lean_ctor_get(x_15, 1); +lean_inc(x_17); +lean_dec(x_15); +x_18 = l_Lean_Meta_mkOfNonempty(x_14, x_4, x_5, x_6, x_7, x_17); +if (lean_obj_tag(x_18) == 0) +{ +lean_dec(x_16); +return x_18; +} +else +{ +uint8_t x_19; +x_19 = !lean_is_exclusive(x_18); +if (x_19 == 0) +{ +lean_object* x_20; +x_20 = lean_ctor_get(x_18, 0); +lean_dec(x_20); +lean_ctor_set(x_18, 0, x_16); +return x_18; +} +else +{ +lean_object* x_21; lean_object* x_22; +x_21 = lean_ctor_get(x_18, 1); +lean_inc(x_21); +lean_dec(x_18); +x_22 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_22, 0, x_16); +lean_ctor_set(x_22, 1, x_21); +return x_22; +} +} +} +} +} +else +{ +uint8_t x_23; +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_2); +lean_dec(x_1); +x_23 = !lean_is_exclusive(x_9); +if (x_23 == 0) +{ +return x_9; +} +else +{ +lean_object* x_24; lean_object* x_25; lean_object* x_26; +x_24 = lean_ctor_get(x_9, 0); +x_25 = lean_ctor_get(x_9, 1); +lean_inc(x_25); +lean_inc(x_24); +lean_dec(x_9); +x_26 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_26, 0, x_24); +lean_ctor_set(x_26, 1, x_25); +return x_26; +} +} +} +} +LEAN_EXPORT lean_object* l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty(lean_object* x_1) { +_start: +{ +lean_object* x_2; +x_2 = lean_alloc_closure((void*)(l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___rarg___boxed), 8, 0); +return x_2; +} +} +LEAN_EXPORT lean_object* l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___rarg___boxed(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) { +_start: +{ +lean_object* x_9; +x_9 = l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___rarg(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8); +lean_dec(x_3); +return x_9; +} +} +LEAN_EXPORT lean_object* l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___boxed(lean_object* x_1) { +_start: +{ +lean_object* x_2; +x_2 = l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty(x_1); +lean_dec(x_1); +return x_2; +} +} +static lean_object* _init_l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__1() { +_start: +{ +lean_object* x_1; +x_1 = lean_mk_string("arbitraryOrOfNonempty"); +return x_1; +} +} +static lean_object* _init_l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__2() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = l___regBuiltin_Lean_Elab_Term_elabBinRel___closed__6; +x_2 = l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__1; +x_3 = lean_name_mk_string(x_1, x_2); +return x_3; +} +} +static lean_object* _init_l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__3() { +_start: +{ +lean_object* x_1; +x_1 = lean_mk_string("elabArbitraryOrNonempty"); +return x_1; +} +} +static lean_object* _init_l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__4() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = l___regBuiltin_Lean_Elab_Term_BinOp_elabBinOp___closed__2; +x_2 = l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__3; +x_3 = lean_name_mk_string(x_1, x_2); +return x_3; +} +} +static lean_object* _init_l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__5() { +_start: +{ +lean_object* x_1; +x_1 = lean_alloc_closure((void*)(l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___boxed), 1, 0); +return x_1; +} +} +LEAN_EXPORT lean_object* l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty(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_Lean_Elab_Term_termElabAttribute; +x_3 = l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__2; +x_4 = l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__4; +x_5 = l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__5; +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_BinOp_elabArbitraryOrNonempty_declRange___closed__1() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = lean_unsigned_to_nat(317u); +x_2 = lean_unsigned_to_nat(0u); +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_BinOp_elabArbitraryOrNonempty_declRange___closed__2() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = lean_unsigned_to_nat(327u); +x_2 = lean_unsigned_to_nat(14u); +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_BinOp_elabArbitraryOrNonempty_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_BinOp_elabArbitraryOrNonempty_declRange___closed__1; +x_2 = lean_unsigned_to_nat(0u); +x_3 = l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__2; +x_4 = lean_unsigned_to_nat(14u); +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_BinOp_elabArbitraryOrNonempty_declRange___closed__4() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = lean_unsigned_to_nat(317u); +x_2 = lean_unsigned_to_nat(4u); +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_BinOp_elabArbitraryOrNonempty_declRange___closed__5() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = lean_unsigned_to_nat(317u); +x_2 = lean_unsigned_to_nat(27u); +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_BinOp_elabArbitraryOrNonempty_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_BinOp_elabArbitraryOrNonempty_declRange___closed__4; +x_2 = lean_unsigned_to_nat(4u); +x_3 = l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__5; +x_4 = lean_unsigned_to_nat(27u); +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_BinOp_elabArbitraryOrNonempty_declRange___closed__7() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__3; +x_2 = l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_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_BinOp_elabArbitraryOrNonempty_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_BinOp_elabArbitraryOrNonempty___closed__4; +x_3 = l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__7; +x_4 = l_Lean_addBuiltinDeclarationRanges(x_2, x_3, x_1); +return x_4; +} +} +LEAN_EXPORT lean_object* l_Lean_Elab_Term_BinOp_initFn____x40_Lean_Elab_Extra___hyg_4993_(lean_object* x_1) { _start: { lean_object* x_2; lean_object* x_3; @@ -15830,7 +16173,41 @@ lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_BinOp_elabBinCalc_declRange__ res = l___regBuiltin_Lean_Elab_Term_BinOp_elabBinCalc_declRange(lean_io_mk_world()); if (lean_io_result_is_error(res)) return res; lean_dec_ref(res); -res = l_Lean_Elab_Term_BinOp_initFn____x40_Lean_Elab_Extra___hyg_4917_(lean_io_mk_world()); +l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___rarg___closed__1 = _init_l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___rarg___closed__1(); +lean_mark_persistent(l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___rarg___closed__1); +l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___rarg___closed__2 = _init_l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___rarg___closed__2(); +lean_mark_persistent(l_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___rarg___closed__2); +l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__1 = _init_l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__1(); +lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__1); +l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__2 = _init_l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__2(); +lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__2); +l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__3 = _init_l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__3(); +lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__3); +l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__4 = _init_l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__4(); +lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__4); +l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__5 = _init_l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__5(); +lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty___closed__5); +res = l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty(lean_io_mk_world()); +if (lean_io_result_is_error(res)) return res; +lean_dec_ref(res); +l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__1 = _init_l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__1(); +lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__1); +l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__2 = _init_l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__2(); +lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__2); +l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__3 = _init_l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__3(); +lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__3); +l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__4 = _init_l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__4(); +lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__4); +l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__5 = _init_l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__5(); +lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__5); +l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__6 = _init_l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__6(); +lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__6); +l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__7 = _init_l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__7(); +lean_mark_persistent(l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange___closed__7); +res = l___regBuiltin_Lean_Elab_Term_BinOp_elabArbitraryOrNonempty_declRange(lean_io_mk_world()); +if (lean_io_result_is_error(res)) return res; +lean_dec_ref(res); +res = l_Lean_Elab_Term_BinOp_initFn____x40_Lean_Elab_Extra___hyg_4993_(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)); diff --git a/stage0/stdlib/Lean/PrettyPrinter/Basic.c b/stage0/stdlib/Lean/PrettyPrinter/Basic.c index 956f0fef89..a3bb077a98 100644 --- a/stage0/stdlib/Lean/PrettyPrinter/Basic.c +++ b/stage0/stdlib/Lean/PrettyPrinter/Basic.c @@ -37,7 +37,6 @@ lean_object* lean_eval_const(lean_object*, lean_object*, lean_object*); lean_object* l_Lean_KeyedDeclsAttribute_getValues___rarg(lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_throwError___at_Lean_PrettyPrinter_runForNodeKind___spec__4___rarg___boxed(lean_object*, lean_object*, lean_object*, lean_object*); uint8_t l_Lean_Expr_isConstOf(lean_object*, lean_object*); -lean_object* l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1(lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_ConstantInfo_type(lean_object*); static lean_object* l_Lean_PrettyPrinter_initFn____x40_Lean_PrettyPrinter_Basic___hyg_5____closed__1; lean_object* l_Lean_registerInternalExceptionId(lean_object*, lean_object*); @@ -50,6 +49,7 @@ LEAN_EXPORT lean_object* l_Lean_ofExcept___at_Lean_PrettyPrinter_runForNodeKind_ LEAN_EXPORT lean_object* l_Lean_ofExcept___at_Lean_PrettyPrinter_runForNodeKind___spec__3___rarg(lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_throwError___at_Lean_PrettyPrinter_runForNodeKind___spec__1___rarg(lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_throwError___at_Lean_PrettyPrinter_runForNodeKind___spec__1___rarg___boxed(lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1(lean_object*, lean_object*, lean_object*, lean_object*); LEAN_EXPORT lean_object* l_Lean_throwError___at_Lean_PrettyPrinter_runForNodeKind___spec__4(lean_object*); static lean_object* l_Lean_PrettyPrinter_runForNodeKind___rarg___closed__12; LEAN_EXPORT lean_object* l_Lean_PrettyPrinter_backtrackExceptionId; @@ -365,7 +365,7 @@ if (lean_obj_tag(x_12) == 0) lean_object* x_13; lean_free_object(x_7); lean_inc(x_2); -x_13 = l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1(x_2, x_4, x_5, x_10); +x_13 = l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1(x_2, x_4, x_5, x_10); if (lean_obj_tag(x_13) == 0) { lean_object* x_14; lean_object* x_15; lean_object* x_16; lean_object* x_17; uint8_t x_18; @@ -566,7 +566,7 @@ if (lean_obj_tag(x_57) == 0) { lean_object* x_58; lean_inc(x_2); -x_58 = l_Lean_getConstInfo___at_Lean_getExternConstArity___spec__1(x_2, x_4, x_5, x_55); +x_58 = l_Lean_getConstInfo___at___private_Lean_Compiler_ExternAttr_0__Lean_getExternConstArity___spec__1(x_2, x_4, x_5, x_55); if (lean_obj_tag(x_58) == 0) { lean_object* x_59; lean_object* x_60; lean_object* x_61; lean_object* x_62; uint8_t x_63;