From dbbb7bf9f6115093197037586afe59180ecff0f2 Mon Sep 17 00:00:00 2001 From: Leonardo de Moura Date: Sun, 4 Apr 2021 11:39:31 -0700 Subject: [PATCH] chore: update stage0 --- stage0/src/Init/Data.lean | 1 + stage0/src/Init/Data/Ord.lean | 39 + stage0/src/Lean/Elab/App.lean | 6 +- stage0/src/Lean/Elab/Deriving.lean | 1 + stage0/src/Lean/Elab/Deriving/Ord.lean | 107 + stage0/src/Lean/Elab/InfoTree.lean | 4 +- stage0/src/Lean/Elab/Term.lean | 4 +- stage0/src/Lean/Server/Completion.lean | 8 +- stage0/stdlib/CMakeLists.txt | 4 +- stage0/stdlib/Init/Data.c | 6 +- stage0/stdlib/Init/Data/Ord.c | 423 ++ stage0/stdlib/Lean/Elab/App.c | 8 +- stage0/stdlib/Lean/Elab/Deriving.c | 6 +- stage0/stdlib/Lean/Elab/Deriving/Ord.c | 5322 ++++++++++++++++++++++++ stage0/stdlib/Lean/Elab/InfoTree.c | 66 +- stage0/stdlib/Lean/Server/Completion.c | 397 +- stage0/stdlib/Lean/Server/FileWorker.c | 246 +- 17 files changed, 6313 insertions(+), 335 deletions(-) create mode 100644 stage0/src/Init/Data/Ord.lean create mode 100644 stage0/src/Lean/Elab/Deriving/Ord.lean create mode 100644 stage0/stdlib/Init/Data/Ord.c create mode 100644 stage0/stdlib/Lean/Elab/Deriving/Ord.c diff --git a/stage0/src/Init/Data.lean b/stage0/src/Init/Data.lean index ecb12e592a..082afdbc40 100644 --- a/stage0/src/Init/Data.lean +++ b/stage0/src/Init/Data.lean @@ -17,6 +17,7 @@ import Init.Data.Fin import Init.Data.UInt import Init.Data.Float import Init.Data.Option +import Init.Data.Ord import Init.Data.Random import Init.Data.ToString import Init.Data.Range diff --git a/stage0/src/Init/Data/Ord.lean b/stage0/src/Init/Data/Ord.lean new file mode 100644 index 0000000000..f4cdff4861 --- /dev/null +++ b/stage0/src/Init/Data/Ord.lean @@ -0,0 +1,39 @@ +/- +Copyright (c) 2021 Microsoft Corporation. All rights reserved. +Released under Apache 2.0 license as described in the file LICENSE. +Author: Dany Fabian +-/ + +prelude +import Init.Data.Int +import Init.Data.String + +inductive Ordering where + | lt | eq | gt +deriving Inhabited + + +class Ord (α : Type u) where + compare : α → α → Ordering + +export Ord (compare) + +def compareOfLessAndEq {α} (x y : α) [HasLess α] [Decidable (x < y)] [DecidableEq α] : Ordering := + if x < y then Ordering.lt + else if x = y then Ordering.eq + else Ordering.gt + +instance : Ord Nat where + compare x y := compareOfLessAndEq x y + +instance : Ord Int where + compare x y := compareOfLessAndEq x y + +instance : Ord Bool where + compare + | false, true => Ordering.lt + | true, false => Ordering.gt + | _, _ => Ordering.eq + +instance : Ord String where + compare x y := compareOfLessAndEq x y diff --git a/stage0/src/Lean/Elab/App.lean b/stage0/src/Lean/Elab/App.lean index 29983087c0..506e4ebc6e 100644 --- a/stage0/src/Lean/Elab/App.lean +++ b/stage0/src/Lean/Elab/App.lean @@ -690,8 +690,8 @@ private def elabAppLValsAux (namedArgs : Array NamedArg) (args : Array Arg) (exp let rec loop : Expr → List LVal → TermElabM Expr | f, [] => elabAppArgs f namedArgs args expectedType? explicit ellipsis | f, lval::lvals => do - if let LVal.fieldName (ref := fieldStx) (stx := stx) .. := lval then - addDotCompletionInfo stx f expectedType? fieldStx + if let LVal.fieldName (ref := fieldStx) (targetStx := targetStx) .. := lval then + addDotCompletionInfo targetStx f expectedType? fieldStx let (f, lvalRes) ← resolveLVal f lval match lvalRes with | LValResolution.projIdx structName idx => @@ -805,7 +805,7 @@ private partial def elabAppFn (f : Syntax) (lvals : List LVal) (namedArgs : Arra let elabFieldName (e field : Syntax) := do let newLVals := field.getId.eraseMacroScopes.components.map fun n => -- We use `none` here since `field` can't be part of a composite name - LVal.fieldName field (toString n) none f + LVal.fieldName field (toString n) none e elabAppFn e (newLVals ++ lvals) namedArgs args expectedType? explicit ellipsis overloaded acc let elabFieldIdx (e idxStx : Syntax) := do let idx := idxStx.isFieldIdx?.get! diff --git a/stage0/src/Lean/Elab/Deriving.lean b/stage0/src/Lean/Elab/Deriving.lean index e6cb0076f1..c483d9c8f8 100644 --- a/stage0/src/Lean/Elab/Deriving.lean +++ b/stage0/src/Lean/Elab/Deriving.lean @@ -12,3 +12,4 @@ import Lean.Elab.Deriving.Repr import Lean.Elab.Deriving.FromToJson import Lean.Elab.Deriving.SizeOf import Lean.Elab.Deriving.Hashable +import Lean.Elab.Deriving.Ord diff --git a/stage0/src/Lean/Elab/Deriving/Ord.lean b/stage0/src/Lean/Elab/Deriving/Ord.lean new file mode 100644 index 0000000000..77f9e0d73e --- /dev/null +++ b/stage0/src/Lean/Elab/Deriving/Ord.lean @@ -0,0 +1,107 @@ +/- +Copyright (c) 2021 Microsoft Corporation. All rights reserved. +Released under Apache 2.0 license as described in the file LICENSE. +Authors: Dany Fabian +-/ +import Lean.Meta.Transform +import Lean.Elab.Deriving.Basic +import Lean.Elab.Deriving.Util + +namespace Lean.Elab.Deriving.Ord +open Lean.Parser.Term +open Meta + +def mkOrdHeader (ctx : Context) (indVal : InductiveVal) : TermElabM Header := do + mkHeader ctx `Ord 2 indVal + +def mkMatch (ctx : Context) (header : Header) (indVal : InductiveVal) (auxFunName : Name) : TermElabM Syntax := do + let discrs ← mkDiscrs header indVal + let alts ← mkAlts + `(match $[$discrs],* with $alts:matchAlt*) +where + mkAlts : TermElabM (Array Syntax) := do + let mut alts := #[] + for ctorName in indVal.ctors do + let ctorInfo ← getConstInfoCtor ctorName + let alt ← forallTelescopeReducing ctorInfo.type fun xs type => do + let type ← Core.betaReduce type -- we 'beta-reduce' to eliminate "artificial" dependencies + let mut indPatterns := #[] + -- add `_` pattern for indices + for i in [:indVal.numIndices] do + indPatterns := indPatterns.push (← `(_)) + let mut ctorArgs1 := #[] + let mut ctorArgs2 := #[] + let mut rhs ← `(Ordering.eq) + -- add `_` for inductive parameters, they are inaccessible + for i in [:indVal.numParams] do + ctorArgs1 := ctorArgs1.push (← `(_)) + ctorArgs2 := ctorArgs2.push (← `(_)) + for i in [:ctorInfo.numFields] do + let x := xs[indVal.numParams + i] + if type.containsFVar x.fvarId! || (←isProp (←inferType x)) then + -- If resulting type depends on this field or is a proof, we don't need to compare + ctorArgs1 := ctorArgs1.push (← `(_)) + ctorArgs2 := ctorArgs2.push (← `(_)) + else + let a := mkIdent (← mkFreshUserName `a) + let b := mkIdent (← mkFreshUserName `b) + ctorArgs1 := ctorArgs1.push a + ctorArgs2 := ctorArgs2.push b + rhs ← `(match compare $a:ident $b:ident with + | Ordering.lt => Ordering.lt + | Ordering.gt => Ordering.gt + | Ordering.eq => $rhs) + let lPat ← `(@$(mkIdent ctorName):ident $ctorArgs1.reverse:term*) + let rPat ← `(@$(mkIdent ctorName):ident $ctorArgs2.reverse:term*) + let patterns := indPatterns ++ #[lPat, rPat] + let ltPatterns := indPatterns ++ #[lPat, ←`(_)] + let gtPatterns := indPatterns ++ #[←`(_), rPat] + #[←`(matchAltExpr| | $[$(patterns):term],* => $rhs:term), + ←`(matchAltExpr| | $[$(ltPatterns):term],* => Ordering.lt), + ←`(matchAltExpr| | $[$(gtPatterns):term],* => Ordering.gt)] + alts := alts ++ alt + return alts.pop.pop + +def mkAuxFunction (ctx : Context) (i : Nat) : TermElabM Syntax := do + let auxFunName ← ctx.auxFunNames[i] + let indVal ← ctx.typeInfos[i] + let header ← mkOrdHeader ctx indVal + let mut body ← mkMatch ctx header indVal auxFunName + if ctx.usePartial || indVal.isRec then + let letDecls ← mkLocalInstanceLetDecls ctx `Ord header.argNames + body ← mkLet letDecls body + let binders := header.binders + if ctx.usePartial || indVal.isRec then + `(private partial def $(mkIdent auxFunName):ident $binders:explicitBinder* : Ordering := $body:term) + else + `(private def $(mkIdent auxFunName):ident $binders:explicitBinder* : Ordering := $body:term) + +def mkMutualBlock (ctx : Context) : TermElabM Syntax := do + let mut auxDefs := #[] + for i in [:ctx.typeInfos.size] do + auxDefs := auxDefs.push (← mkAuxFunction ctx i) + `(mutual + $auxDefs:command* + end) + +private def mkOrdInstanceCmds (declNames : Array Name) : TermElabM (Array Syntax) := do + let ctx ← mkContext "ord" declNames[0] + let cmds := #[← mkMutualBlock ctx] ++ (← mkInstanceCmds ctx `Ord declNames) + trace[Elab.Deriving.ord] "\n{cmds}" + return cmds + +open Command + +def mkOrdInstanceHandler (declNames : Array Name) : CommandElabM Bool := do + if (← declNames.allM isInductive) && declNames.size > 0 then + let cmds ← liftTermElabM none <| mkOrdInstanceCmds declNames + cmds.forM elabCommand + return true + else + return false + +builtin_initialize + registerBuiltinDerivingHandler `Ord mkOrdInstanceHandler + registerTraceClass `Elab.Deriving.ord + +end Lean.Elab.Deriving.Ord diff --git a/stage0/src/Lean/Elab/InfoTree.lean b/stage0/src/Lean/Elab/InfoTree.lean index d8fc18fac6..96d214458b 100644 --- a/stage0/src/Lean/Elab/InfoTree.lean +++ b/stage0/src/Lean/Elab/InfoTree.lean @@ -161,8 +161,8 @@ def TermInfo.format (ctx : ContextInfo) (info : TermInfo) : IO Format := do def CompletionInfo.format (ctx : ContextInfo) (info : CompletionInfo) : IO Format := match info with | CompletionInfo.dot i .. => return f!"[.] {← i.format ctx}" - | CompletionInfo.id stx lctx expectedType? => ctx.runMetaM lctx do return f!"[.] {stx} : {expectedType?}" - | _ => return f!"[.] {info.stx}" + | CompletionInfo.id stx lctx expectedType? => ctx.runMetaM lctx do return f!"[.] {stx} : {expectedType?} @ {formatStxRange ctx info.stx}" + | _ => return f!"[.] {info.stx} @ {formatStxRange ctx info.stx}" def CommandInfo.format (ctx : ContextInfo) (info : CommandInfo) : IO Format := do return f!"command @ {formatStxRange ctx info.stx}" diff --git a/stage0/src/Lean/Elab/Term.lean b/stage0/src/Lean/Elab/Term.lean index 70f254d817..148ca20e34 100644 --- a/stage0/src/Lean/Elab/Term.lean +++ b/stage0/src/Lean/Elab/Term.lean @@ -309,8 +309,8 @@ builtin_initialize termElabAttribute : KeyedDeclsAttribute TermElab ← mkTermEl inductive LVal where | fieldIdx (ref : Syntax) (i : Nat) /- Field `suffix?` is for producing better error messages because `x.y` may be a field access or a hierachical/composite name. - `ref` is the syntax object representing the field only. `stx` contains the object + field -/ - | fieldName (ref : Syntax) (name : String) (suffix? : Option Name) (stx : Syntax) + `ref` is the syntax object representing the field. `targetStx` is the target object being accessed. -/ + | fieldName (ref : Syntax) (name : String) (suffix? : Option Name) (targetStx : Syntax) | getOp (ref : Syntax) (idx : Syntax) def LVal.getRef : LVal → Syntax diff --git a/stage0/src/Lean/Server/Completion.lean b/stage0/src/Lean/Server/Completion.lean index ecef1b7758..48ada17ccc 100644 --- a/stage0/src/Lean/Server/Completion.lean +++ b/stage0/src/Lean/Server/Completion.lean @@ -6,6 +6,7 @@ Authors: Leonardo de Moura import Lean.Environment import Lean.Data.Lsp.LanguageFeatures import Lean.Meta.Tactic.Apply +import Lean.Meta.Match.MatcherInfo import Lean.Server.InfoUtils import Lean.Parser.Extension @@ -22,7 +23,12 @@ def addToBlackList (env : Environment) (declName : Name) : Environment := private def isBlackListed (declName : Name) : MetaM Bool := do let env ← getEnv - return declName.isInternal || isAuxRecursor env declName || isNoConfusion env declName || (← isRec declName) || completionBlackListExt.isTagged env declName + declName.isInternal + <||> isAuxRecursor env declName + <||> isNoConfusion env declName + <||> isRec declName + <||> completionBlackListExt.isTagged env declName + <||> isMatcher declName private partial def consumeImplicitPrefix (e : Expr) : MetaM Expr := do match e with diff --git a/stage0/stdlib/CMakeLists.txt b/stage0/stdlib/CMakeLists.txt index 7c6d017c4e..90f0560d39 100644 --- a/stage0/stdlib/CMakeLists.txt +++ b/stage0/stdlib/CMakeLists.txt @@ -1,6 +1,6 @@ -add_library (Init STATIC Init.c Init/Classical.c Init/Coe.c Init/Control.c Init/Control/Basic.c Init/Control/EState.c Init/Control/Except.c Init/Control/ExceptCps.c Init/Control/Id.c Init/Control/Lawful.c Init/Control/Option.c Init/Control/Reader.c Init/Control/State.c Init/Control/StateCps.c Init/Control/StateRef.c Init/Core.c Init/Data.c Init/Data/Array.c Init/Data/Array/Basic.c Init/Data/Array/BinSearch.c Init/Data/Array/InsertionSort.c Init/Data/Array/QSort.c Init/Data/Array/Subarray.c Init/Data/Basic.c Init/Data/ByteArray.c Init/Data/ByteArray/Basic.c Init/Data/Char.c Init/Data/Char/Basic.c Init/Data/Fin.c Init/Data/Fin/Basic.c Init/Data/Float.c Init/Data/FloatArray.c Init/Data/FloatArray/Basic.c Init/Data/Format.c Init/Data/Format/Basic.c Init/Data/Format/Instances.c Init/Data/Format/Macro.c Init/Data/Format/Syntax.c Init/Data/Hashable.c Init/Data/Int.c Init/Data/Int/Basic.c Init/Data/List.c Init/Data/List/Basic.c Init/Data/List/BasicAux.c Init/Data/List/Control.c Init/Data/Nat.c Init/Data/Nat/Basic.c Init/Data/Nat/Bitwise.c Init/Data/Nat/Control.c Init/Data/Nat/Div.c Init/Data/Nat/Gcd.c Init/Data/OfScientific.c Init/Data/Option.c Init/Data/Option/Basic.c Init/Data/Option/BasicAux.c Init/Data/Option/Instances.c Init/Data/Random.c Init/Data/Range.c Init/Data/Repr.c Init/Data/Stream.c Init/Data/String.c Init/Data/String/Basic.c Init/Data/String/Extra.c Init/Data/ToString.c Init/Data/ToString/Basic.c Init/Data/ToString/Macro.c Init/Data/UInt.c Init/Fix.c Init/Hints.c Init/Meta.c Init/Notation.c Init/NotationExtra.c Init/Prelude.c Init/SimpLemmas.c Init/SizeOf.c Init/System.c Init/System/FilePath.c Init/System/IO.c Init/System/IOError.c Init/System/Platform.c Init/System/ST.c Init/Util.c Init/WF.c ) +add_library (Init STATIC Init.c Init/Classical.c Init/Coe.c Init/Control.c Init/Control/Basic.c Init/Control/EState.c Init/Control/Except.c Init/Control/ExceptCps.c Init/Control/Id.c Init/Control/Lawful.c Init/Control/Option.c Init/Control/Reader.c Init/Control/State.c Init/Control/StateCps.c Init/Control/StateRef.c Init/Core.c Init/Data.c Init/Data/Array.c Init/Data/Array/Basic.c Init/Data/Array/BinSearch.c Init/Data/Array/InsertionSort.c Init/Data/Array/QSort.c Init/Data/Array/Subarray.c Init/Data/Basic.c Init/Data/ByteArray.c Init/Data/ByteArray/Basic.c Init/Data/Char.c Init/Data/Char/Basic.c Init/Data/Fin.c Init/Data/Fin/Basic.c Init/Data/Float.c Init/Data/FloatArray.c Init/Data/FloatArray/Basic.c Init/Data/Format.c Init/Data/Format/Basic.c Init/Data/Format/Instances.c Init/Data/Format/Macro.c Init/Data/Format/Syntax.c Init/Data/Hashable.c Init/Data/Int.c Init/Data/Int/Basic.c Init/Data/List.c Init/Data/List/Basic.c Init/Data/List/BasicAux.c Init/Data/List/Control.c Init/Data/Nat.c Init/Data/Nat/Basic.c Init/Data/Nat/Bitwise.c Init/Data/Nat/Control.c Init/Data/Nat/Div.c Init/Data/Nat/Gcd.c Init/Data/OfScientific.c Init/Data/Option.c Init/Data/Option/Basic.c Init/Data/Option/BasicAux.c Init/Data/Option/Instances.c Init/Data/Ord.c Init/Data/Random.c Init/Data/Range.c Init/Data/Repr.c Init/Data/Stream.c Init/Data/String.c Init/Data/String/Basic.c Init/Data/String/Extra.c Init/Data/ToString.c Init/Data/ToString/Basic.c Init/Data/ToString/Macro.c Init/Data/UInt.c Init/Fix.c Init/Hints.c Init/Meta.c Init/Notation.c Init/NotationExtra.c Init/Prelude.c Init/SimpLemmas.c Init/SizeOf.c Init/System.c Init/System/FilePath.c Init/System/IO.c Init/System/IOError.c Init/System/Platform.c Init/System/ST.c Init/Util.c Init/WF.c ) set_target_properties(Init PROPERTIES ARCHIVE_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/lib/lean") add_library (Std STATIC Std.c Std/Control.c Std/Control/Nondet.c Std/Data.c Std/Data/AssocList.c Std/Data/BinomialHeap.c Std/Data/DList.c Std/Data/HashMap.c Std/Data/HashSet.c Std/Data/PersistentArray.c Std/Data/PersistentHashMap.c Std/Data/PersistentHashSet.c Std/Data/Queue.c Std/Data/RBMap.c Std/Data/RBTree.c Std/Data/Stack.c Std/ShareCommon.c ) set_target_properties(Std PROPERTIES ARCHIVE_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/lib/lean") -add_library (Lean STATIC Lean.c Lean/Attributes.c Lean/AuxRecursor.c Lean/Class.c Lean/Compiler.c Lean/Compiler/BorrowedAnnotation.c Lean/Compiler/ClosedTermCache.c Lean/Compiler/ConstFolding.c Lean/Compiler/ExportAttr.c Lean/Compiler/ExternAttr.c Lean/Compiler/IR.c Lean/Compiler/IR/Basic.c Lean/Compiler/IR/Borrow.c Lean/Compiler/IR/Boxing.c Lean/Compiler/IR/Checker.c Lean/Compiler/IR/CompilerM.c Lean/Compiler/IR/CtorLayout.c Lean/Compiler/IR/ElimDeadBranches.c Lean/Compiler/IR/ElimDeadVars.c Lean/Compiler/IR/EmitC.c Lean/Compiler/IR/EmitUtil.c Lean/Compiler/IR/ExpandResetReuse.c Lean/Compiler/IR/Format.c Lean/Compiler/IR/FreeVars.c Lean/Compiler/IR/LiveVars.c Lean/Compiler/IR/NormIds.c Lean/Compiler/IR/PushProj.c Lean/Compiler/IR/RC.c Lean/Compiler/IR/ResetReuse.c Lean/Compiler/IR/SimpCase.c Lean/Compiler/IR/Sorry.c Lean/Compiler/IR/UnboxResult.c Lean/Compiler/ImplementedByAttr.c Lean/Compiler/InitAttr.c Lean/Compiler/InlineAttrs.c Lean/Compiler/NameMangling.c Lean/Compiler/NeverExtractAttr.c Lean/Compiler/Specialize.c Lean/Compiler/Util.c Lean/CoreM.c Lean/Data.c Lean/Data/Format.c Lean/Data/Json.c Lean/Data/Json/Basic.c Lean/Data/Json/FromToJson.c Lean/Data/Json/Parser.c Lean/Data/Json/Printer.c Lean/Data/Json/Stream.c Lean/Data/JsonRpc.c Lean/Data/KVMap.c Lean/Data/LBool.c Lean/Data/LOption.c Lean/Data/Lsp.c Lean/Data/Lsp/Basic.c Lean/Data/Lsp/Capabilities.c Lean/Data/Lsp/Communication.c Lean/Data/Lsp/Diagnostics.c Lean/Data/Lsp/Extra.c Lean/Data/Lsp/InitShutdown.c Lean/Data/Lsp/Ipc.c Lean/Data/Lsp/LanguageFeatures.c Lean/Data/Lsp/TextSync.c Lean/Data/Lsp/Utf16.c Lean/Data/Lsp/Workspace.c Lean/Data/Name.c Lean/Data/NameTrie.c Lean/Data/Occurrences.c Lean/Data/OpenDecl.c Lean/Data/Options.c Lean/Data/Position.c Lean/Data/PrefixTree.c Lean/Data/SMap.c Lean/Data/Trie.c Lean/Declaration.c Lean/DeclarationRange.c Lean/DocString.c Lean/Elab.c Lean/Elab/App.c Lean/Elab/Attributes.c Lean/Elab/AutoBound.c Lean/Elab/Binders.c Lean/Elab/BuiltinNotation.c Lean/Elab/Command.c Lean/Elab/DeclModifiers.c Lean/Elab/DeclUtil.c Lean/Elab/Declaration.c Lean/Elab/DeclarationRange.c Lean/Elab/DefView.c Lean/Elab/Deriving.c Lean/Elab/Deriving/BEq.c Lean/Elab/Deriving/Basic.c Lean/Elab/Deriving/DecEq.c Lean/Elab/Deriving/FromToJson.c Lean/Elab/Deriving/Hashable.c Lean/Elab/Deriving/Inhabited.c Lean/Elab/Deriving/Repr.c Lean/Elab/Deriving/SizeOf.c Lean/Elab/Deriving/Util.c Lean/Elab/Do.c Lean/Elab/Exception.c Lean/Elab/Extra.c Lean/Elab/Frontend.c Lean/Elab/Import.c Lean/Elab/Inductive.c Lean/Elab/InfoTree.c Lean/Elab/LetRec.c Lean/Elab/Level.c Lean/Elab/Log.c Lean/Elab/Match.c Lean/Elab/MutualDef.c Lean/Elab/Open.c Lean/Elab/PreDefinition.c Lean/Elab/PreDefinition/Basic.c Lean/Elab/PreDefinition/Main.c Lean/Elab/PreDefinition/MkInhabitant.c Lean/Elab/PreDefinition/Structural.c Lean/Elab/PreDefinition/WF.c Lean/Elab/Print.c Lean/Elab/Quotation.c Lean/Elab/Quotation/Util.c Lean/Elab/SetOption.c Lean/Elab/StructInst.c Lean/Elab/Structure.c Lean/Elab/Syntax.c Lean/Elab/SyntheticMVars.c Lean/Elab/Tactic.c Lean/Elab/Tactic/Basic.c Lean/Elab/Tactic/ElabTerm.c Lean/Elab/Tactic/Generalize.c Lean/Elab/Tactic/Induction.c Lean/Elab/Tactic/Injection.c Lean/Elab/Tactic/Location.c Lean/Elab/Tactic/Match.c Lean/Elab/Tactic/Rewrite.c Lean/Elab/Tactic/Simp.c Lean/Elab/Term.c Lean/Elab/Util.c Lean/Environment.c Lean/Eval.c Lean/Exception.c Lean/Expr.c Lean/HeadIndex.c Lean/Hygiene.c Lean/InternalExceptionId.c Lean/KeyedDeclsAttribute.c Lean/Level.c Lean/LocalContext.c Lean/Message.c Lean/Meta.c Lean/Meta/AbstractMVars.c Lean/Meta/AbstractNestedProofs.c Lean/Meta/AppBuilder.c Lean/Meta/Basic.c Lean/Meta/Check.c Lean/Meta/Closure.c Lean/Meta/Coe.c Lean/Meta/CollectFVars.c Lean/Meta/CollectMVars.c Lean/Meta/DiscrTree.c Lean/Meta/DiscrTreeTypes.c Lean/Meta/ExprDefEq.c Lean/Meta/ForEachExpr.c Lean/Meta/FunInfo.c Lean/Meta/GeneralizeTelescope.c Lean/Meta/GetConst.c Lean/Meta/Inductive.c Lean/Meta/InferType.c Lean/Meta/Instances.c Lean/Meta/KAbstract.c Lean/Meta/LevelDefEq.c Lean/Meta/Match.c Lean/Meta/Match/Basic.c Lean/Meta/Match/CaseArraySizes.c Lean/Meta/Match/CaseValues.c Lean/Meta/Match/MVarRenaming.c Lean/Meta/Match/Match.c Lean/Meta/Match/MatchPatternAttr.c Lean/Meta/Match/MatcherInfo.c Lean/Meta/MatchUtil.c Lean/Meta/Offset.c Lean/Meta/PPGoal.c Lean/Meta/RecursorInfo.c Lean/Meta/Reduce.c Lean/Meta/ReduceEval.c Lean/Meta/SizeOf.c Lean/Meta/SortLocalDecls.c Lean/Meta/SynthInstance.c Lean/Meta/Tactic.c Lean/Meta/Tactic/Apply.c Lean/Meta/Tactic/Assert.c Lean/Meta/Tactic/Assumption.c Lean/Meta/Tactic/AuxLemma.c Lean/Meta/Tactic/Cases.c Lean/Meta/Tactic/Clear.c Lean/Meta/Tactic/Constructor.c Lean/Meta/Tactic/Contradiction.c Lean/Meta/Tactic/Delta.c Lean/Meta/Tactic/ElimInfo.c Lean/Meta/Tactic/FVarSubst.c Lean/Meta/Tactic/Generalize.c Lean/Meta/Tactic/Induction.c Lean/Meta/Tactic/Injection.c Lean/Meta/Tactic/Intro.c Lean/Meta/Tactic/Replace.c Lean/Meta/Tactic/Revert.c Lean/Meta/Tactic/Rewrite.c Lean/Meta/Tactic/Simp.c Lean/Meta/Tactic/Simp/CongrLemmas.c Lean/Meta/Tactic/Simp/Main.c Lean/Meta/Tactic/Simp/Rewrite.c Lean/Meta/Tactic/Simp/SimpAll.c Lean/Meta/Tactic/Simp/SimpLemmas.c Lean/Meta/Tactic/Simp/Types.c Lean/Meta/Tactic/Subst.c Lean/Meta/Tactic/Util.c Lean/Meta/Transform.c Lean/Meta/TransparencyMode.c Lean/Meta/UnificationHint.c Lean/Meta/WHNF.c Lean/MetavarContext.c Lean/Modifiers.c Lean/MonadEnv.c Lean/Parser.c Lean/Parser/Attr.c Lean/Parser/Basic.c Lean/Parser/Command.c Lean/Parser/Do.c Lean/Parser/Extension.c Lean/Parser/Extra.c Lean/Parser/Level.c Lean/Parser/Module.c Lean/Parser/StrInterpolation.c Lean/Parser/Syntax.c Lean/Parser/Tactic.c Lean/Parser/Term.c Lean/ParserCompiler.c Lean/ParserCompiler/Attribute.c Lean/PrettyPrinter.c Lean/PrettyPrinter/Basic.c Lean/PrettyPrinter/Delaborator.c Lean/PrettyPrinter/Delaborator/Basic.c Lean/PrettyPrinter/Delaborator/Builtins.c Lean/PrettyPrinter/Formatter.c Lean/PrettyPrinter/Parenthesizer.c Lean/ProjFns.c Lean/ReducibilityAttrs.c Lean/ResolveName.c Lean/Runtime.c Lean/ScopedEnvExtension.c Lean/Server.c Lean/Server/AsyncList.c Lean/Server/Completion.c Lean/Server/FileSource.c Lean/Server/FileWorker.c Lean/Server/InfoUtils.c Lean/Server/Snapshots.c Lean/Server/Utils.c Lean/Server/Watchdog.c Lean/Structure.c Lean/Syntax.c Lean/ToExpr.c Lean/Util.c Lean/Util/CollectFVars.c Lean/Util/CollectLevelParams.c Lean/Util/CollectMVars.c Lean/Util/Constructions.c Lean/Util/FindExpr.c Lean/Util/FindMVar.c Lean/Util/FoldConsts.c Lean/Util/ForEachExpr.c Lean/Util/MonadCache.c Lean/Util/OccursCheck.c Lean/Util/PPExt.c Lean/Util/Path.c Lean/Util/Profile.c Lean/Util/RecDepth.c Lean/Util/Recognizers.c Lean/Util/ReplaceExpr.c Lean/Util/ReplaceLevel.c Lean/Util/SCC.c Lean/Util/Sorry.c Lean/Util/Trace.c ) +add_library (Lean STATIC Lean.c Lean/Attributes.c Lean/AuxRecursor.c Lean/Class.c Lean/Compiler.c Lean/Compiler/BorrowedAnnotation.c Lean/Compiler/ClosedTermCache.c Lean/Compiler/ConstFolding.c Lean/Compiler/ExportAttr.c Lean/Compiler/ExternAttr.c Lean/Compiler/IR.c Lean/Compiler/IR/Basic.c Lean/Compiler/IR/Borrow.c Lean/Compiler/IR/Boxing.c Lean/Compiler/IR/Checker.c Lean/Compiler/IR/CompilerM.c Lean/Compiler/IR/CtorLayout.c Lean/Compiler/IR/ElimDeadBranches.c Lean/Compiler/IR/ElimDeadVars.c Lean/Compiler/IR/EmitC.c Lean/Compiler/IR/EmitUtil.c Lean/Compiler/IR/ExpandResetReuse.c Lean/Compiler/IR/Format.c Lean/Compiler/IR/FreeVars.c Lean/Compiler/IR/LiveVars.c Lean/Compiler/IR/NormIds.c Lean/Compiler/IR/PushProj.c Lean/Compiler/IR/RC.c Lean/Compiler/IR/ResetReuse.c Lean/Compiler/IR/SimpCase.c Lean/Compiler/IR/Sorry.c Lean/Compiler/IR/UnboxResult.c Lean/Compiler/ImplementedByAttr.c Lean/Compiler/InitAttr.c Lean/Compiler/InlineAttrs.c Lean/Compiler/NameMangling.c Lean/Compiler/NeverExtractAttr.c Lean/Compiler/Specialize.c Lean/Compiler/Util.c Lean/CoreM.c Lean/Data.c Lean/Data/Format.c Lean/Data/Json.c Lean/Data/Json/Basic.c Lean/Data/Json/FromToJson.c Lean/Data/Json/Parser.c Lean/Data/Json/Printer.c Lean/Data/Json/Stream.c Lean/Data/JsonRpc.c Lean/Data/KVMap.c Lean/Data/LBool.c Lean/Data/LOption.c Lean/Data/Lsp.c Lean/Data/Lsp/Basic.c Lean/Data/Lsp/Capabilities.c Lean/Data/Lsp/Communication.c Lean/Data/Lsp/Diagnostics.c Lean/Data/Lsp/Extra.c Lean/Data/Lsp/InitShutdown.c Lean/Data/Lsp/Ipc.c Lean/Data/Lsp/LanguageFeatures.c Lean/Data/Lsp/TextSync.c Lean/Data/Lsp/Utf16.c Lean/Data/Lsp/Workspace.c Lean/Data/Name.c Lean/Data/NameTrie.c Lean/Data/Occurrences.c Lean/Data/OpenDecl.c Lean/Data/Options.c Lean/Data/Position.c Lean/Data/PrefixTree.c Lean/Data/SMap.c Lean/Data/Trie.c Lean/Declaration.c Lean/DeclarationRange.c Lean/DocString.c Lean/Elab.c Lean/Elab/App.c Lean/Elab/Attributes.c Lean/Elab/AutoBound.c Lean/Elab/Binders.c Lean/Elab/BuiltinNotation.c Lean/Elab/Command.c Lean/Elab/DeclModifiers.c Lean/Elab/DeclUtil.c Lean/Elab/Declaration.c Lean/Elab/DeclarationRange.c Lean/Elab/DefView.c Lean/Elab/Deriving.c Lean/Elab/Deriving/BEq.c Lean/Elab/Deriving/Basic.c Lean/Elab/Deriving/DecEq.c Lean/Elab/Deriving/FromToJson.c Lean/Elab/Deriving/Hashable.c Lean/Elab/Deriving/Inhabited.c Lean/Elab/Deriving/Ord.c Lean/Elab/Deriving/Repr.c Lean/Elab/Deriving/SizeOf.c Lean/Elab/Deriving/Util.c Lean/Elab/Do.c Lean/Elab/Exception.c Lean/Elab/Extra.c Lean/Elab/Frontend.c Lean/Elab/Import.c Lean/Elab/Inductive.c Lean/Elab/InfoTree.c Lean/Elab/LetRec.c Lean/Elab/Level.c Lean/Elab/Log.c Lean/Elab/Match.c Lean/Elab/MutualDef.c Lean/Elab/Open.c Lean/Elab/PreDefinition.c Lean/Elab/PreDefinition/Basic.c Lean/Elab/PreDefinition/Main.c Lean/Elab/PreDefinition/MkInhabitant.c Lean/Elab/PreDefinition/Structural.c Lean/Elab/PreDefinition/WF.c Lean/Elab/Print.c Lean/Elab/Quotation.c Lean/Elab/Quotation/Util.c Lean/Elab/SetOption.c Lean/Elab/StructInst.c Lean/Elab/Structure.c Lean/Elab/Syntax.c Lean/Elab/SyntheticMVars.c Lean/Elab/Tactic.c Lean/Elab/Tactic/Basic.c Lean/Elab/Tactic/ElabTerm.c Lean/Elab/Tactic/Generalize.c Lean/Elab/Tactic/Induction.c Lean/Elab/Tactic/Injection.c Lean/Elab/Tactic/Location.c Lean/Elab/Tactic/Match.c Lean/Elab/Tactic/Rewrite.c Lean/Elab/Tactic/Simp.c Lean/Elab/Term.c Lean/Elab/Util.c Lean/Environment.c Lean/Eval.c Lean/Exception.c Lean/Expr.c Lean/HeadIndex.c Lean/Hygiene.c Lean/InternalExceptionId.c Lean/KeyedDeclsAttribute.c Lean/Level.c Lean/LocalContext.c Lean/Message.c Lean/Meta.c Lean/Meta/AbstractMVars.c Lean/Meta/AbstractNestedProofs.c Lean/Meta/AppBuilder.c Lean/Meta/Basic.c Lean/Meta/Check.c Lean/Meta/Closure.c Lean/Meta/Coe.c Lean/Meta/CollectFVars.c Lean/Meta/CollectMVars.c Lean/Meta/DiscrTree.c Lean/Meta/DiscrTreeTypes.c Lean/Meta/ExprDefEq.c Lean/Meta/ForEachExpr.c Lean/Meta/FunInfo.c Lean/Meta/GeneralizeTelescope.c Lean/Meta/GetConst.c Lean/Meta/Inductive.c Lean/Meta/InferType.c Lean/Meta/Instances.c Lean/Meta/KAbstract.c Lean/Meta/LevelDefEq.c Lean/Meta/Match.c Lean/Meta/Match/Basic.c Lean/Meta/Match/CaseArraySizes.c Lean/Meta/Match/CaseValues.c Lean/Meta/Match/MVarRenaming.c Lean/Meta/Match/Match.c Lean/Meta/Match/MatchPatternAttr.c Lean/Meta/Match/MatcherInfo.c Lean/Meta/MatchUtil.c Lean/Meta/Offset.c Lean/Meta/PPGoal.c Lean/Meta/RecursorInfo.c Lean/Meta/Reduce.c Lean/Meta/ReduceEval.c Lean/Meta/SizeOf.c Lean/Meta/SortLocalDecls.c Lean/Meta/SynthInstance.c Lean/Meta/Tactic.c Lean/Meta/Tactic/Apply.c Lean/Meta/Tactic/Assert.c Lean/Meta/Tactic/Assumption.c Lean/Meta/Tactic/AuxLemma.c Lean/Meta/Tactic/Cases.c Lean/Meta/Tactic/Clear.c Lean/Meta/Tactic/Constructor.c Lean/Meta/Tactic/Contradiction.c Lean/Meta/Tactic/Delta.c Lean/Meta/Tactic/ElimInfo.c Lean/Meta/Tactic/FVarSubst.c Lean/Meta/Tactic/Generalize.c Lean/Meta/Tactic/Induction.c Lean/Meta/Tactic/Injection.c Lean/Meta/Tactic/Intro.c Lean/Meta/Tactic/Replace.c Lean/Meta/Tactic/Revert.c Lean/Meta/Tactic/Rewrite.c Lean/Meta/Tactic/Simp.c Lean/Meta/Tactic/Simp/CongrLemmas.c Lean/Meta/Tactic/Simp/Main.c Lean/Meta/Tactic/Simp/Rewrite.c Lean/Meta/Tactic/Simp/SimpAll.c Lean/Meta/Tactic/Simp/SimpLemmas.c Lean/Meta/Tactic/Simp/Types.c Lean/Meta/Tactic/Subst.c Lean/Meta/Tactic/Util.c Lean/Meta/Transform.c Lean/Meta/TransparencyMode.c Lean/Meta/UnificationHint.c Lean/Meta/WHNF.c Lean/MetavarContext.c Lean/Modifiers.c Lean/MonadEnv.c Lean/Parser.c Lean/Parser/Attr.c Lean/Parser/Basic.c Lean/Parser/Command.c Lean/Parser/Do.c Lean/Parser/Extension.c Lean/Parser/Extra.c Lean/Parser/Level.c Lean/Parser/Module.c Lean/Parser/StrInterpolation.c Lean/Parser/Syntax.c Lean/Parser/Tactic.c Lean/Parser/Term.c Lean/ParserCompiler.c Lean/ParserCompiler/Attribute.c Lean/PrettyPrinter.c Lean/PrettyPrinter/Basic.c Lean/PrettyPrinter/Delaborator.c Lean/PrettyPrinter/Delaborator/Basic.c Lean/PrettyPrinter/Delaborator/Builtins.c Lean/PrettyPrinter/Formatter.c Lean/PrettyPrinter/Parenthesizer.c Lean/ProjFns.c Lean/ReducibilityAttrs.c Lean/ResolveName.c Lean/Runtime.c Lean/ScopedEnvExtension.c Lean/Server.c Lean/Server/AsyncList.c Lean/Server/Completion.c Lean/Server/FileSource.c Lean/Server/FileWorker.c Lean/Server/InfoUtils.c Lean/Server/Snapshots.c Lean/Server/Utils.c Lean/Server/Watchdog.c Lean/Structure.c Lean/Syntax.c Lean/ToExpr.c Lean/Util.c Lean/Util/CollectFVars.c Lean/Util/CollectLevelParams.c Lean/Util/CollectMVars.c Lean/Util/Constructions.c Lean/Util/FindExpr.c Lean/Util/FindMVar.c Lean/Util/FoldConsts.c Lean/Util/ForEachExpr.c Lean/Util/MonadCache.c Lean/Util/OccursCheck.c Lean/Util/PPExt.c Lean/Util/Path.c Lean/Util/Profile.c Lean/Util/RecDepth.c Lean/Util/Recognizers.c Lean/Util/ReplaceExpr.c Lean/Util/ReplaceLevel.c Lean/Util/SCC.c Lean/Util/Sorry.c Lean/Util/Trace.c ) set_target_properties(Lean PROPERTIES ARCHIVE_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/lib/lean") diff --git a/stage0/stdlib/Init/Data.c b/stage0/stdlib/Init/Data.c index bd129d68d2..14fe7ab1e9 100644 --- a/stage0/stdlib/Init/Data.c +++ b/stage0/stdlib/Init/Data.c @@ -1,6 +1,6 @@ // Lean compiler output // Module: Init.Data -// Imports: Init.Data.Basic Init.Data.Nat Init.Data.Char Init.Data.String Init.Data.List Init.Data.Int Init.Data.Array Init.Data.ByteArray Init.Data.FloatArray Init.Data.Fin Init.Data.UInt Init.Data.Float Init.Data.Option Init.Data.Random Init.Data.ToString Init.Data.Range Init.Data.Hashable Init.Data.OfScientific Init.Data.Format Init.Data.Stream +// Imports: Init.Data.Basic Init.Data.Nat Init.Data.Char Init.Data.String Init.Data.List Init.Data.Int Init.Data.Array Init.Data.ByteArray Init.Data.FloatArray Init.Data.Fin Init.Data.UInt Init.Data.Float Init.Data.Option Init.Data.Ord Init.Data.Random Init.Data.ToString Init.Data.Range Init.Data.Hashable Init.Data.OfScientific Init.Data.Format Init.Data.Stream #include #if defined(__clang__) #pragma clang diagnostic ignored "-Wunused-parameter" @@ -26,6 +26,7 @@ lean_object* initialize_Init_Data_Fin(lean_object*); lean_object* initialize_Init_Data_UInt(lean_object*); lean_object* initialize_Init_Data_Float(lean_object*); lean_object* initialize_Init_Data_Option(lean_object*); +lean_object* initialize_Init_Data_Ord(lean_object*); lean_object* initialize_Init_Data_Random(lean_object*); lean_object* initialize_Init_Data_ToString(lean_object*); lean_object* initialize_Init_Data_Range(lean_object*); @@ -77,6 +78,9 @@ lean_dec_ref(res); res = initialize_Init_Data_Option(lean_io_mk_world()); if (lean_io_result_is_error(res)) return res; lean_dec_ref(res); +res = initialize_Init_Data_Ord(lean_io_mk_world()); +if (lean_io_result_is_error(res)) return res; +lean_dec_ref(res); res = initialize_Init_Data_Random(lean_io_mk_world()); if (lean_io_result_is_error(res)) return res; lean_dec_ref(res); diff --git a/stage0/stdlib/Init/Data/Ord.c b/stage0/stdlib/Init/Data/Ord.c new file mode 100644 index 0000000000..194c6a8c2c --- /dev/null +++ b/stage0/stdlib/Init/Data/Ord.c @@ -0,0 +1,423 @@ +// Lean compiler output +// Module: Init.Data.Ord +// Imports: Init.Data.Int Init.Data.String +#include +#if defined(__clang__) +#pragma clang diagnostic ignored "-Wunused-parameter" +#pragma clang diagnostic ignored "-Wunused-label" +#elif defined(__GNUC__) && !defined(__CLANG__) +#pragma GCC diagnostic ignored "-Wunused-parameter" +#pragma GCC diagnostic ignored "-Wunused-label" +#pragma GCC diagnostic ignored "-Wunused-but-set-variable" +#endif +#ifdef __cplusplus +extern "C" { +#endif +uint8_t l_instOrdBool(uint8_t, uint8_t); +lean_object* l_compareOfLessAndEq___at_instOrdString___spec__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_instOrdNat___boxed(lean_object*, lean_object*); +uint8_t lean_nat_dec_eq(lean_object*, lean_object*); +lean_object* l_instOrdBool_match__1(lean_object*); +uint8_t l_instInhabitedOrdering; +lean_object* l_instOrdBool_match__1___rarg(uint8_t, uint8_t, lean_object*, lean_object*, lean_object*); +lean_object* l_compareOfLessAndEq___at_instOrdNat___spec__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*); +uint8_t l_compareOfLessAndEq___at_instOrdInt___spec__1(lean_object*, lean_object*, lean_object*, lean_object*); +uint8_t l_instOrdInt(lean_object*, lean_object*); +uint8_t l_instOrdNat(lean_object*, lean_object*); +lean_object* l_compareOfLessAndEq___at_instOrdInt___spec__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_instOrdString___boxed(lean_object*, lean_object*); +lean_object* l_instOrdBool___boxed(lean_object*, lean_object*); +uint8_t l_compareOfLessAndEq___rarg(lean_object*, lean_object*, lean_object*, uint8_t, lean_object*); +uint8_t lean_int_dec_lt(lean_object*, lean_object*); +lean_object* l_instOrdInt___boxed(lean_object*, lean_object*); +uint8_t l_instOrdString(lean_object*, lean_object*); +uint8_t l_compareOfLessAndEq___at_instOrdNat___spec__1(lean_object*, lean_object*, lean_object*, lean_object*); +uint8_t lean_int_dec_eq(lean_object*, lean_object*); +lean_object* l_instOrdBool_match__1___rarg___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_compareOfLessAndEq(lean_object*); +lean_object* l_compareOfLessAndEq___rarg___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +uint8_t l_compareOfLessAndEq___at_instOrdString___spec__1(lean_object*, lean_object*, lean_object*, lean_object*); +uint8_t lean_string_dec_lt(lean_object*, lean_object*); +uint8_t lean_string_dec_eq(lean_object*, lean_object*); +uint8_t lean_nat_dec_lt(lean_object*, lean_object*); +static uint8_t _init_l_instInhabitedOrdering() { +_start: +{ +uint8_t x_1; +x_1 = 0; +return x_1; +} +} +uint8_t l_compareOfLessAndEq___rarg(lean_object* x_1, lean_object* x_2, lean_object* x_3, uint8_t x_4, lean_object* x_5) { +_start: +{ +if (x_4 == 0) +{ +lean_object* x_6; uint8_t x_7; +x_6 = lean_apply_2(x_5, x_1, x_2); +x_7 = lean_unbox(x_6); +lean_dec(x_6); +if (x_7 == 0) +{ +uint8_t x_8; +x_8 = 2; +return x_8; +} +else +{ +uint8_t x_9; +x_9 = 1; +return x_9; +} +} +else +{ +uint8_t x_10; +lean_dec(x_5); +lean_dec(x_2); +lean_dec(x_1); +x_10 = 0; +return x_10; +} +} +} +lean_object* l_compareOfLessAndEq(lean_object* x_1) { +_start: +{ +lean_object* x_2; +x_2 = lean_alloc_closure((void*)(l_compareOfLessAndEq___rarg___boxed), 5, 0); +return x_2; +} +} +lean_object* l_compareOfLessAndEq___rarg___boxed(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5) { +_start: +{ +uint8_t x_6; uint8_t x_7; lean_object* x_8; +x_6 = lean_unbox(x_4); +lean_dec(x_4); +x_7 = l_compareOfLessAndEq___rarg(x_1, x_2, x_3, x_6, x_5); +lean_dec(x_3); +x_8 = lean_box(x_7); +return x_8; +} +} +uint8_t l_compareOfLessAndEq___at_instOrdNat___spec__1(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4) { +_start: +{ +uint8_t x_5; +x_5 = lean_nat_dec_lt(x_1, x_2); +if (x_5 == 0) +{ +uint8_t x_6; +x_6 = lean_nat_dec_eq(x_3, x_4); +if (x_6 == 0) +{ +uint8_t x_7; +x_7 = 2; +return x_7; +} +else +{ +uint8_t x_8; +x_8 = 1; +return x_8; +} +} +else +{ +uint8_t x_9; +x_9 = 0; +return x_9; +} +} +} +uint8_t l_instOrdNat(lean_object* x_1, lean_object* x_2) { +_start: +{ +uint8_t x_3; +x_3 = l_compareOfLessAndEq___at_instOrdNat___spec__1(x_1, x_2, x_1, x_2); +return x_3; +} +} +lean_object* l_compareOfLessAndEq___at_instOrdNat___spec__1___boxed(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4) { +_start: +{ +uint8_t x_5; lean_object* x_6; +x_5 = l_compareOfLessAndEq___at_instOrdNat___spec__1(x_1, x_2, x_3, x_4); +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_2); +lean_dec(x_1); +x_6 = lean_box(x_5); +return x_6; +} +} +lean_object* l_instOrdNat___boxed(lean_object* x_1, lean_object* x_2) { +_start: +{ +uint8_t x_3; lean_object* x_4; +x_3 = l_instOrdNat(x_1, x_2); +lean_dec(x_2); +lean_dec(x_1); +x_4 = lean_box(x_3); +return x_4; +} +} +uint8_t l_compareOfLessAndEq___at_instOrdInt___spec__1(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4) { +_start: +{ +uint8_t x_5; +x_5 = lean_int_dec_lt(x_1, x_2); +if (x_5 == 0) +{ +uint8_t x_6; +x_6 = lean_int_dec_eq(x_3, x_4); +if (x_6 == 0) +{ +uint8_t x_7; +x_7 = 2; +return x_7; +} +else +{ +uint8_t x_8; +x_8 = 1; +return x_8; +} +} +else +{ +uint8_t x_9; +x_9 = 0; +return x_9; +} +} +} +uint8_t l_instOrdInt(lean_object* x_1, lean_object* x_2) { +_start: +{ +uint8_t x_3; +x_3 = l_compareOfLessAndEq___at_instOrdInt___spec__1(x_1, x_2, x_1, x_2); +return x_3; +} +} +lean_object* l_compareOfLessAndEq___at_instOrdInt___spec__1___boxed(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4) { +_start: +{ +uint8_t x_5; lean_object* x_6; +x_5 = l_compareOfLessAndEq___at_instOrdInt___spec__1(x_1, x_2, x_3, x_4); +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_2); +lean_dec(x_1); +x_6 = lean_box(x_5); +return x_6; +} +} +lean_object* l_instOrdInt___boxed(lean_object* x_1, lean_object* x_2) { +_start: +{ +uint8_t x_3; lean_object* x_4; +x_3 = l_instOrdInt(x_1, x_2); +lean_dec(x_2); +lean_dec(x_1); +x_4 = lean_box(x_3); +return x_4; +} +} +lean_object* l_instOrdBool_match__1___rarg(uint8_t x_1, uint8_t x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5) { +_start: +{ +if (x_1 == 0) +{ +lean_dec(x_4); +if (x_2 == 0) +{ +lean_object* x_6; lean_object* x_7; lean_object* x_8; +lean_dec(x_3); +x_6 = lean_box(x_2); +x_7 = lean_box(x_2); +x_8 = lean_apply_2(x_5, x_6, x_7); +return x_8; +} +else +{ +lean_object* x_9; lean_object* x_10; +lean_dec(x_5); +x_9 = lean_box(0); +x_10 = lean_apply_1(x_3, x_9); +return x_10; +} +} +else +{ +lean_dec(x_3); +if (x_2 == 0) +{ +lean_object* x_11; lean_object* x_12; +lean_dec(x_5); +x_11 = lean_box(0); +x_12 = lean_apply_1(x_4, x_11); +return x_12; +} +else +{ +lean_object* x_13; lean_object* x_14; lean_object* x_15; +lean_dec(x_4); +x_13 = lean_box(x_2); +x_14 = lean_box(x_2); +x_15 = lean_apply_2(x_5, x_13, x_14); +return x_15; +} +} +} +} +lean_object* l_instOrdBool_match__1(lean_object* x_1) { +_start: +{ +lean_object* x_2; +x_2 = lean_alloc_closure((void*)(l_instOrdBool_match__1___rarg___boxed), 5, 0); +return x_2; +} +} +lean_object* l_instOrdBool_match__1___rarg___boxed(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5) { +_start: +{ +uint8_t x_6; uint8_t x_7; lean_object* x_8; +x_6 = lean_unbox(x_1); +lean_dec(x_1); +x_7 = lean_unbox(x_2); +lean_dec(x_2); +x_8 = l_instOrdBool_match__1___rarg(x_6, x_7, x_3, x_4, x_5); +return x_8; +} +} +uint8_t l_instOrdBool(uint8_t x_1, uint8_t x_2) { +_start: +{ +if (x_1 == 0) +{ +if (x_2 == 0) +{ +uint8_t x_3; +x_3 = 1; +return x_3; +} +else +{ +uint8_t x_4; +x_4 = 0; +return x_4; +} +} +else +{ +if (x_2 == 0) +{ +uint8_t x_5; +x_5 = 2; +return x_5; +} +else +{ +uint8_t x_6; +x_6 = 1; +return x_6; +} +} +} +} +lean_object* l_instOrdBool___boxed(lean_object* x_1, lean_object* x_2) { +_start: +{ +uint8_t x_3; uint8_t x_4; uint8_t x_5; lean_object* x_6; +x_3 = lean_unbox(x_1); +lean_dec(x_1); +x_4 = lean_unbox(x_2); +lean_dec(x_2); +x_5 = l_instOrdBool(x_3, x_4); +x_6 = lean_box(x_5); +return x_6; +} +} +uint8_t l_compareOfLessAndEq___at_instOrdString___spec__1(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4) { +_start: +{ +uint8_t x_5; +x_5 = lean_string_dec_lt(x_1, x_2); +if (x_5 == 0) +{ +uint8_t x_6; +x_6 = lean_string_dec_eq(x_3, x_4); +if (x_6 == 0) +{ +uint8_t x_7; +x_7 = 2; +return x_7; +} +else +{ +uint8_t x_8; +x_8 = 1; +return x_8; +} +} +else +{ +uint8_t x_9; +x_9 = 0; +return x_9; +} +} +} +uint8_t l_instOrdString(lean_object* x_1, lean_object* x_2) { +_start: +{ +uint8_t x_3; +x_3 = l_compareOfLessAndEq___at_instOrdString___spec__1(x_1, x_2, x_1, x_2); +return x_3; +} +} +lean_object* l_compareOfLessAndEq___at_instOrdString___spec__1___boxed(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4) { +_start: +{ +uint8_t x_5; lean_object* x_6; +x_5 = l_compareOfLessAndEq___at_instOrdString___spec__1(x_1, x_2, x_3, x_4); +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_2); +lean_dec(x_1); +x_6 = lean_box(x_5); +return x_6; +} +} +lean_object* l_instOrdString___boxed(lean_object* x_1, lean_object* x_2) { +_start: +{ +uint8_t x_3; lean_object* x_4; +x_3 = l_instOrdString(x_1, x_2); +lean_dec(x_2); +lean_dec(x_1); +x_4 = lean_box(x_3); +return x_4; +} +} +lean_object* initialize_Init_Data_Int(lean_object*); +lean_object* initialize_Init_Data_String(lean_object*); +static bool _G_initialized = false; +lean_object* initialize_Init_Data_Ord(lean_object* w) { +lean_object * res; +if (_G_initialized) return lean_io_result_mk_ok(lean_box(0)); +_G_initialized = true; +res = initialize_Init_Data_Int(lean_io_mk_world()); +if (lean_io_result_is_error(res)) return res; +lean_dec_ref(res); +res = initialize_Init_Data_String(lean_io_mk_world()); +if (lean_io_result_is_error(res)) return res; +lean_dec_ref(res); +l_instInhabitedOrdering = _init_l_instInhabitedOrdering(); +return lean_io_result_mk_ok(lean_box(0)); +} +#ifdef __cplusplus +} +#endif diff --git a/stage0/stdlib/Lean/Elab/App.c b/stage0/stdlib/Lean/Elab/App.c index 4624455a9e..bcf9991f03 100644 --- a/stage0/stdlib/Lean/Elab/App.c +++ b/stage0/stdlib/Lean/Elab/App.c @@ -27670,10 +27670,12 @@ goto block_348; else { lean_object* x_1753; lean_object* x_1754; lean_object* x_1755; lean_object* x_1756; lean_object* x_1757; +lean_dec(x_1); x_1753 = l_Lean_Syntax_getId(x_1409); x_1754 = lean_erase_macro_scopes(x_1753); x_1755 = l_Lean_Name_components(x_1754); -x_1756 = l_List_map___at___private_Lean_Elab_App_0__Lean_Elab_Term_elabAppFn___spec__3(x_1, x_1409, x_1755); +lean_inc(x_1407); +x_1756 = l_List_map___at___private_Lean_Elab_App_0__Lean_Elab_Term_elabAppFn___spec__3(x_1407, x_1409, x_1755); x_1757 = l_List_append___rarg(x_1756, x_2); x_1 = x_1407; x_2 = x_1757; @@ -29338,10 +29340,12 @@ return x_2096; else { lean_object* x_2118; lean_object* x_2119; lean_object* x_2120; lean_object* x_2121; lean_object* x_2122; +lean_dec(x_1); x_2118 = l_Lean_Syntax_getId(x_1783); x_2119 = lean_erase_macro_scopes(x_2118); x_2120 = l_Lean_Name_components(x_2119); -x_2121 = l_List_map___at___private_Lean_Elab_App_0__Lean_Elab_Term_elabAppFn___spec__4(x_1, x_1783, x_2120); +lean_inc(x_1781); +x_2121 = l_List_map___at___private_Lean_Elab_App_0__Lean_Elab_Term_elabAppFn___spec__4(x_1781, x_1783, x_2120); x_2122 = l_List_append___rarg(x_2121, x_2); x_1 = x_1781; x_2 = x_2122; diff --git a/stage0/stdlib/Lean/Elab/Deriving.c b/stage0/stdlib/Lean/Elab/Deriving.c index fec7bb52e4..a02c3d604f 100644 --- a/stage0/stdlib/Lean/Elab/Deriving.c +++ b/stage0/stdlib/Lean/Elab/Deriving.c @@ -1,6 +1,6 @@ // Lean compiler output // Module: Lean.Elab.Deriving -// Imports: Init Lean.Elab.Deriving.Basic Lean.Elab.Deriving.Util Lean.Elab.Deriving.Inhabited Lean.Elab.Deriving.BEq Lean.Elab.Deriving.DecEq Lean.Elab.Deriving.Repr Lean.Elab.Deriving.FromToJson Lean.Elab.Deriving.SizeOf Lean.Elab.Deriving.Hashable +// Imports: Init Lean.Elab.Deriving.Basic Lean.Elab.Deriving.Util Lean.Elab.Deriving.Inhabited Lean.Elab.Deriving.BEq Lean.Elab.Deriving.DecEq Lean.Elab.Deriving.Repr Lean.Elab.Deriving.FromToJson Lean.Elab.Deriving.SizeOf Lean.Elab.Deriving.Hashable Lean.Elab.Deriving.Ord #include #if defined(__clang__) #pragma clang diagnostic ignored "-Wunused-parameter" @@ -23,6 +23,7 @@ lean_object* initialize_Lean_Elab_Deriving_Repr(lean_object*); lean_object* initialize_Lean_Elab_Deriving_FromToJson(lean_object*); lean_object* initialize_Lean_Elab_Deriving_SizeOf(lean_object*); lean_object* initialize_Lean_Elab_Deriving_Hashable(lean_object*); +lean_object* initialize_Lean_Elab_Deriving_Ord(lean_object*); static bool _G_initialized = false; lean_object* initialize_Lean_Elab_Deriving(lean_object* w) { lean_object * res; @@ -58,6 +59,9 @@ lean_dec_ref(res); res = initialize_Lean_Elab_Deriving_Hashable(lean_io_mk_world()); if (lean_io_result_is_error(res)) return res; lean_dec_ref(res); +res = initialize_Lean_Elab_Deriving_Ord(lean_io_mk_world()); +if (lean_io_result_is_error(res)) return res; +lean_dec_ref(res); return lean_io_result_mk_ok(lean_box(0)); } #ifdef __cplusplus diff --git a/stage0/stdlib/Lean/Elab/Deriving/Ord.c b/stage0/stdlib/Lean/Elab/Deriving/Ord.c new file mode 100644 index 0000000000..01de3df560 --- /dev/null +++ b/stage0/stdlib/Lean/Elab/Deriving/Ord.c @@ -0,0 +1,5322 @@ +// Lean compiler output +// Module: Lean.Elab.Deriving.Ord +// Imports: Init Lean.Meta.Transform Lean.Elab.Deriving.Basic Lean.Elab.Deriving.Util +#include +#if defined(__clang__) +#pragma clang diagnostic ignored "-Wunused-parameter" +#pragma clang diagnostic ignored "-Wunused-label" +#elif defined(__GNUC__) && !defined(__CLANG__) +#pragma GCC diagnostic ignored "-Wunused-parameter" +#pragma GCC diagnostic ignored "-Wunused-label" +#pragma GCC diagnostic ignored "-Wunused-but-set-variable" +#endif +#ifdef __cplusplus +extern "C" { +#endif +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__5; +lean_object* l_Lean_getConstInfo___at_Lean_Elab_Term_mkConst___spec__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_List_map___at___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___spec__1(lean_object*); +uint8_t l_Lean_Expr_hasAnyFVar_visit___at_Lean_Expr_containsFVar___spec__1(lean_object*, lean_object*); +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__14; +size_t l_USize_add(size_t, size_t); +extern lean_object* l_myMacro____x40_Init_Notation___hyg_14458____closed__14; +lean_object* l_Lean_registerTraceClass(lean_object*, lean_object*); +extern lean_object* l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__33; +extern lean_object* l_Lean_Elab_Deriving_mkContext___closed__2; +lean_object* l_Lean_Elab_Command_liftTermElabM___rarg(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* lean_name_mk_string(lean_object*, lean_object*); +extern lean_object* l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__5; +uint8_t l_USize_decEq(size_t, size_t); +lean_object* lean_array_uget(lean_object*, size_t); +lean_object* l_Array_append___rarg(lean_object*, lean_object*); +extern lean_object* l_Array_myMacro____x40_Init_Data_Array_Subarray___hyg_936____closed__4; +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__2; +lean_object* l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +extern lean_object* l_Array_empty___closed__1; +lean_object* l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___closed__2; +lean_object* lean_environment_find(lean_object*, lean_object*); +lean_object* lean_st_ref_get(lean_object*, lean_object*); +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__7; +extern lean_object* l_myMacro____x40_Init_Notation___hyg_14458____closed__6; +lean_object* l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +extern lean_object* l_Lean_Parser_Command_mutual___elambda__1___closed__2; +lean_object* l_Lean_Meta_forallTelescopeReducing___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__6(lean_object*); +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__3(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* lean_array_push(lean_object*, lean_object*); +lean_object* l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* lean_array_get_size(lean_object*); +lean_object* l_Lean_Elab_Deriving_Ord_mkOrdHeader(lean_object*); +lean_object* l_Lean_Meta_forallTelescope___at___private_Lean_Elab_Term_0__Lean_Elab_Term_tryPureCoe_x3f___spec__1___rarg___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_MessageData_ofList(lean_object*); +lean_object* l_Lean_throwError___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__2___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +extern lean_object* l_Array_foldlMUnsafe_fold___at___private_Lean_Util_Trace_0__Lean_withNestedTracesFinalizer___spec__5___closed__1; +extern lean_object* l_myMacro____x40_Init_Notation___hyg_15378____closed__9; +extern lean_object* l_Lean_Parser_Command_mutual___elambda__1___closed__1; +lean_object* lean_string_utf8_byte_size(lean_object*); +lean_object* l_Lean_Elab_Term_getMainModule___rarg(lean_object*, lean_object*); +extern lean_object* l_myMacro____x40_Init_Notation___hyg_1481____closed__8; +lean_object* l_Lean_Elab_Deriving_Ord_mkMutualBlock___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_Elab_Deriving_mkLocalInstanceLetDecls(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* lean_nat_add(lean_object*, lean_object*); +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMutualBlock___spec__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_object* l_Lean_Elab_Deriving_Ord_mkAuxFunction___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +extern lean_object* l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__20; +extern lean_object* l_myMacro____x40_Init_NotationExtra___hyg_5662____closed__28; +lean_object* l_Lean_Elab_Deriving_mkDiscrs(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__3; +lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___spec__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__15; +lean_object* l_Lean_getConstInfoCtor___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_Elab_Deriving_Ord_mkAuxFunction___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_object*); +lean_object* l___private_Lean_CoreM_0__Lean_Core_mkFreshNameImp(lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_Meta_forallTelescopeReducing___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__6___rarg(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +uint8_t lean_nat_dec_eq(lean_object*, lean_object*); +lean_object* l_Lean_Elab_Deriving_Ord_mkMatch(lean_object*); +lean_object* l_Lean_isInductive___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___spec__2___boxed(lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_Elab_Deriving_Ord_mkMatch_mkAlts_match__2(lean_object*); +lean_object* l_Lean_Elab_Deriving_mkInstanceCmds(lean_object*, lean_object*, lean_object*, uint8_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__3___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__11; +lean_object* lean_nat_sub(lean_object*, lean_object*); +lean_object* l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(lean_object*, lean_object*, lean_object*); +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__4; +extern lean_object* l_myMacro____x40_Init_Notation___hyg_14458____closed__10; +lean_object* l___private_Lean_Meta_Basic_0__Lean_Meta_forallTelescopeReducingImp___rarg(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_Elab_Deriving_Ord_mkMatch___rarg___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__6; +lean_object* l_Lean_Elab_Deriving_mkLet(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* lean_array_get(lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler(lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_Elab_Deriving_Ord_mkMatch_mkAlts_match__1(lean_object*); +lean_object* l_Lean_Expr_fvarId_x21(lean_object*); +lean_object* l_Lean_isInductive___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___spec__2(lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__4; +extern lean_object* l_Lean_Core_betaReduce___closed__2; +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__8; +extern lean_object* l_myMacro____x40_Init_Notation___hyg_13856____closed__13; +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__1; +lean_object* l_Lean_Elab_Deriving_Ord_mkMutualBlock(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__8; +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_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__2; +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__6; +lean_object* l_Lean_Elab_Term_getCurrMacroScope(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* lean_array_to_list(lean_object*, lean_object*); +extern lean_object* l_Lean_instInhabitedExpr; +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__11; +lean_object* l_Array_reverse___rarg(lean_object*); +extern lean_object* l_Lean_KernelException_toMessageData___closed__15; +extern lean_object* l_myMacro____x40_Init_Notation___hyg_14458____closed__11; +lean_object* l_Lean_mkSepArray(lean_object*, lean_object*); +lean_object* l_Lean_Elab_Command_elabCommand(lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__13; +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__4(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_Core_transform___at_Lean_Core_betaReduce___spec__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_Elab_Deriving_mkHeader___rarg(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_Elab_Deriving_mkContext(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +extern lean_object* l_Lean_KernelException_toMessageData___closed__3; +size_t lean_usize_of_nat(lean_object*); +extern lean_object* l_Lean_Syntax_mkAntiquotNode___closed__9; +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*); +extern lean_object* l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__25; +extern lean_object* l_Lean_Parser_Tactic_inductionAlt___closed__5; +lean_object* l_Lean_Elab_Deriving_Ord_mkMatch_mkAlts_match__1___rarg(lean_object*, lean_object*); +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__10; +extern lean_object* l_Lean_nullKind___closed__2; +lean_object* l_Array_anyMUnsafe_any___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___spec__3(lean_object*, size_t, size_t, lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_Elab_Deriving_Ord_initFn____x40_Lean_Elab_Deriving_Ord___hyg_2565_(lean_object*); +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__12; +extern lean_object* l_myMacro____x40_Init_NotationExtra___hyg_5662____closed__4; +lean_object* l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__4; +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__9; +lean_object* l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +extern lean_object* l_Lean_Syntax_mkApp___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_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMutualBlock___spec__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +extern lean_object* l_Lean_Parser_Command_end___elambda__1___closed__1; +uint8_t lean_nat_dec_le(lean_object*, lean_object*); +extern lean_object* l_Lean_Parser_Command_private___elambda__1___closed__1; +extern lean_object* l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__7; +lean_object* l_Lean_Elab_Deriving_Ord_initFn____x40_Lean_Elab_Deriving_Ord___hyg_2565____closed__1; +lean_object* l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg___closed__1; +extern lean_object* l_myMacro____x40_Init_NotationExtra___hyg_5201____closed__6; +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__9; +lean_object* l_Array_appendCore___rarg(lean_object*, lean_object*); +lean_object* l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__1; +lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___spec__1(lean_object*, size_t, size_t, lean_object*, lean_object*, lean_object*, lean_object*); +extern lean_object* l_Lean_Core_betaReduce___closed__1; +lean_object* l_Lean_Elab_Deriving_Ord_mkOrdHeader___boxed(lean_object*); +lean_object* l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__2; +lean_object* l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__3; +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___boxed(lean_object**); +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__10; +lean_object* l_Lean_addMessageContextFull___at_Lean_Meta_instAddMessageContextMetaM___spec__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__7; +extern lean_object* l_Lean_instInhabitedName; +extern lean_object* l_Lean_getConstInfoCtor___rarg___lambda__1___closed__2; +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__4___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_Meta_inferType(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_Elab_registerBuiltinDerivingHandler(lean_object*, lean_object*, lean_object*); +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__13; +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__1; +extern lean_object* l_myMacro____x40_Init_Notation___hyg_14458____closed__13; +lean_object* lean_array_pop(lean_object*); +lean_object* l_Lean_Elab_Deriving_Ord_mkAuxFunction(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__14; +extern lean_object* l_myMacro____x40_Init_Notation___hyg_14458____closed__1; +extern lean_object* l_IO_Prim_fopenFlags___closed__4; +lean_object* l_Array_mapMUnsafe_map___at_myMacro____x40_Init_NotationExtra___hyg_5201____spec__3(size_t, size_t, lean_object*); +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__5; +extern lean_object* l_myMacro____x40_Init_Notation___hyg_14458____closed__8; +lean_object* l_Lean_Elab_Deriving_Ord_mkMatch___rarg(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Array_anyMUnsafe_any___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___spec__3___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +extern lean_object* l_myMacro____x40_Init_Notation___hyg_2278____closed__4; +extern lean_object* l_myMacro____x40_Init_Notation___hyg_14458____closed__2; +lean_object* lean_mk_syntax_ident(lean_object*); +extern lean_object* l_Lean_Parser_Command_private___elambda__1___closed__2; +extern lean_object* l_Lean_instInhabitedInductiveVal; +lean_object* l_Lean_throwError___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___closed__1; +extern lean_object* l_Lean_mkOptionalNode___closed__2; +extern lean_object* l_Lean_Parser_Command_partial___elambda__1___closed__1; +extern lean_object* l_myMacro____x40_Init_Notation___hyg_14458____closed__4; +extern lean_object* l_Lean_Parser_Command_partial___elambda__1___closed__2; +lean_object* l_Lean_Elab_Deriving_Ord_mkMatch_mkAlts_match__2___rarg(lean_object*, lean_object*); +extern lean_object* l_Lean_expandExplicitBindersAux_loop___closed__4; +lean_object* l_Lean_getConstInfoCtor___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___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_object*); +lean_object* l_unsafeCast(lean_object*, lean_object*, lean_object*); +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__12; +lean_object* l_Lean_Elab_Deriving_Ord_mkMatch_mkAlts(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_Meta_isProp(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_mkConst(lean_object*, lean_object*); +lean_object* l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg___closed__2; +extern lean_object* l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__21; +lean_object* l_Lean_Elab_Deriving_Ord_mkMatch___boxed(lean_object*); +extern lean_object* l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__23; +lean_object* l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInductiveApp___spec__2___rarg(lean_object*, lean_object*, lean_object*); +extern lean_object* l_myMacro____x40_Init_Notation___hyg_15947____closed__11; +lean_object* l_Lean_Elab_getBetterRef(lean_object*, lean_object*); +uint8_t lean_nat_dec_lt(lean_object*, lean_object*); +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__3; +static lean_object* _init_l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg___closed__1() { +_start: +{ +lean_object* x_1; +x_1 = lean_mk_string("Ord"); +return x_1; +} +} +static lean_object* _init_l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg___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_Deriving_Ord_mkOrdHeader___rarg___closed__1; +x_3 = lean_name_mk_string(x_1, x_2); +return x_3; +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkOrdHeader___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_object* x_10; lean_object* x_11; +x_9 = l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg___closed__2; +x_10 = lean_unsigned_to_nat(2u); +x_11 = l_Lean_Elab_Deriving_mkHeader___rarg(x_9, x_10, x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8); +return x_11; +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkOrdHeader(lean_object* x_1) { +_start: +{ +lean_object* x_2; +x_2 = lean_alloc_closure((void*)(l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg), 8, 0); +return x_2; +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkOrdHeader___boxed(lean_object* x_1) { +_start: +{ +lean_object* x_2; +x_2 = l_Lean_Elab_Deriving_Ord_mkOrdHeader(x_1); +lean_dec(x_1); +return x_2; +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkMatch_mkAlts_match__1___rarg(lean_object* x_1, lean_object* x_2) { +_start: +{ +lean_object* x_3; lean_object* x_4; lean_object* x_5; lean_object* x_6; lean_object* x_7; +x_3 = lean_ctor_get(x_1, 1); +lean_inc(x_3); +x_4 = lean_ctor_get(x_1, 0); +lean_inc(x_4); +lean_dec(x_1); +x_5 = lean_ctor_get(x_3, 0); +lean_inc(x_5); +x_6 = lean_ctor_get(x_3, 1); +lean_inc(x_6); +lean_dec(x_3); +x_7 = lean_apply_3(x_2, x_4, x_5, x_6); +return x_7; +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkMatch_mkAlts_match__1(lean_object* x_1) { +_start: +{ +lean_object* x_2; +x_2 = lean_alloc_closure((void*)(l_Lean_Elab_Deriving_Ord_mkMatch_mkAlts_match__1___rarg), 2, 0); +return x_2; +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkMatch_mkAlts_match__2___rarg(lean_object* x_1, lean_object* x_2) { +_start: +{ +lean_object* x_3; lean_object* x_4; lean_object* x_5; +x_3 = lean_ctor_get(x_1, 0); +lean_inc(x_3); +x_4 = lean_ctor_get(x_1, 1); +lean_inc(x_4); +lean_dec(x_1); +x_5 = lean_apply_2(x_2, x_3, x_4); +return x_5; +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkMatch_mkAlts_match__2(lean_object* x_1) { +_start: +{ +lean_object* x_2; +x_2 = lean_alloc_closure((void*)(l_Lean_Elab_Deriving_Ord_mkMatch_mkAlts_match__2___rarg), 2, 0); +return x_2; +} +} +lean_object* l_Lean_throwError___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__2(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_object* x_10; lean_object* x_11; lean_object* x_12; lean_object* x_13; lean_object* x_14; lean_object* x_15; uint8_t x_16; +x_9 = lean_ctor_get(x_6, 3); +x_10 = lean_ctor_get(x_2, 3); +lean_inc(x_10); +lean_inc(x_10); +x_11 = l_Lean_Elab_getBetterRef(x_9, x_10); +x_12 = l_Lean_addMessageContextFull___at_Lean_Meta_instAddMessageContextMetaM___spec__1(x_1, x_4, x_5, x_6, x_7, x_8); +x_13 = lean_ctor_get(x_12, 0); +lean_inc(x_13); +x_14 = lean_ctor_get(x_12, 1); +lean_inc(x_14); +lean_dec(x_12); +x_15 = l_Lean_Elab_addMacroStack___at_Lean_Elab_Term_instAddErrorMessageContextTermElabM___spec__1(x_13, x_10, x_2, x_3, x_4, x_5, x_6, x_7, x_14); +lean_dec(x_2); +lean_dec(x_10); +x_16 = !lean_is_exclusive(x_15); +if (x_16 == 0) +{ +lean_object* x_17; lean_object* x_18; +x_17 = lean_ctor_get(x_15, 0); +x_18 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_18, 0, x_11); +lean_ctor_set(x_18, 1, x_17); +lean_ctor_set_tag(x_15, 1); +lean_ctor_set(x_15, 0, x_18); +return x_15; +} +else +{ +lean_object* x_19; lean_object* x_20; lean_object* x_21; lean_object* x_22; +x_19 = lean_ctor_get(x_15, 0); +x_20 = lean_ctor_get(x_15, 1); +lean_inc(x_20); +lean_inc(x_19); +lean_dec(x_15); +x_21 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_21, 0, x_11); +lean_ctor_set(x_21, 1, x_19); +x_22 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_22, 0, x_21); +lean_ctor_set(x_22, 1, x_20); +return x_22; +} +} +} +lean_object* l_Lean_getConstInfoCtor___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__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_object* x_8) { +_start: +{ +lean_object* x_9; +lean_inc(x_2); +lean_inc(x_1); +x_9 = l_Lean_getConstInfo___at_Lean_Elab_Term_mkConst___spec__1(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8); +if (lean_obj_tag(x_9) == 0) +{ +lean_object* x_10; +x_10 = lean_ctor_get(x_9, 0); +lean_inc(x_10); +if (lean_obj_tag(x_10) == 6) +{ +uint8_t x_11; +lean_dec(x_2); +lean_dec(x_1); +x_11 = !lean_is_exclusive(x_9); +if (x_11 == 0) +{ +lean_object* x_12; lean_object* x_13; +x_12 = lean_ctor_get(x_9, 0); +lean_dec(x_12); +x_13 = lean_ctor_get(x_10, 0); +lean_inc(x_13); +lean_dec(x_10); +lean_ctor_set(x_9, 0, x_13); +return x_9; +} +else +{ +lean_object* x_14; lean_object* x_15; lean_object* x_16; +x_14 = lean_ctor_get(x_9, 1); +lean_inc(x_14); +lean_dec(x_9); +x_15 = lean_ctor_get(x_10, 0); +lean_inc(x_15); +lean_dec(x_10); +x_16 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_16, 0, x_15); +lean_ctor_set(x_16, 1, x_14); +return x_16; +} +} +else +{ +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_dec(x_10); +x_17 = lean_ctor_get(x_9, 1); +lean_inc(x_17); +lean_dec(x_9); +x_18 = lean_box(0); +x_19 = l_Lean_mkConst(x_1, x_18); +x_20 = lean_alloc_ctor(2, 1, 0); +lean_ctor_set(x_20, 0, x_19); +x_21 = l_Lean_KernelException_toMessageData___closed__3; +x_22 = lean_alloc_ctor(10, 2, 0); +lean_ctor_set(x_22, 0, x_21); +lean_ctor_set(x_22, 1, x_20); +x_23 = l_Lean_getConstInfoCtor___rarg___lambda__1___closed__2; +x_24 = lean_alloc_ctor(10, 2, 0); +lean_ctor_set(x_24, 0, x_22); +lean_ctor_set(x_24, 1, x_23); +x_25 = l_Lean_throwError___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__2(x_24, x_2, x_3, x_4, x_5, x_6, x_7, x_17); +return x_25; +} +} +else +{ +uint8_t x_26; +lean_dec(x_2); +lean_dec(x_1); +x_26 = !lean_is_exclusive(x_9); +if (x_26 == 0) +{ +return x_9; +} +else +{ +lean_object* x_27; lean_object* x_28; lean_object* x_29; +x_27 = lean_ctor_get(x_9, 0); +x_28 = lean_ctor_get(x_9, 1); +lean_inc(x_28); +lean_inc(x_27); +lean_dec(x_9); +x_29 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_29, 0, x_27); +lean_ctor_set(x_29, 1, x_28); +return x_29; +} +} +} +} +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__3(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6, lean_object* x_7, lean_object* x_8, lean_object* x_9, lean_object* x_10, lean_object* x_11, lean_object* x_12) { +_start: +{ +lean_object* x_13; uint8_t x_14; +x_13 = lean_ctor_get(x_2, 1); +x_14 = lean_nat_dec_le(x_13, x_4); +if (x_14 == 0) +{ +lean_object* x_15; uint8_t x_16; +x_15 = lean_unsigned_to_nat(0u); +x_16 = lean_nat_dec_eq(x_3, x_15); +if (x_16 == 0) +{ +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; +x_17 = lean_unsigned_to_nat(1u); +x_18 = lean_nat_sub(x_3, x_17); +lean_dec(x_3); +x_19 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_10, x_11, x_12); +x_20 = lean_ctor_get(x_19, 0); +lean_inc(x_20); +x_21 = lean_ctor_get(x_19, 1); +lean_inc(x_21); +lean_dec(x_19); +x_22 = l_Lean_Elab_Term_getCurrMacroScope(x_6, x_7, x_8, x_9, x_10, x_11, x_21); +x_23 = lean_ctor_get(x_22, 1); +lean_inc(x_23); +lean_dec(x_22); +x_24 = l_Lean_Elab_Term_getMainModule___rarg(x_11, x_23); +x_25 = lean_ctor_get(x_24, 1); +lean_inc(x_25); +lean_dec(x_24); +x_26 = l_myMacro____x40_Init_Notation___hyg_14458____closed__14; +x_27 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_27, 0, x_20); +lean_ctor_set(x_27, 1, x_26); +lean_inc(x_1); +x_28 = lean_array_push(x_1, x_27); +x_29 = l_myMacro____x40_Init_Notation___hyg_14458____closed__13; +x_30 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_30, 0, x_29); +lean_ctor_set(x_30, 1, x_28); +x_31 = lean_array_push(x_5, x_30); +x_32 = lean_ctor_get(x_2, 2); +x_33 = lean_nat_add(x_4, x_32); +lean_dec(x_4); +x_3 = x_18; +x_4 = x_33; +x_5 = x_31; +x_12 = x_25; +goto _start; +} +else +{ +lean_object* x_35; +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_1); +x_35 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_35, 0, x_5); +lean_ctor_set(x_35, 1, x_12); +return x_35; +} +} +else +{ +lean_object* x_36; +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_1); +x_36 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_36, 0, x_5); +lean_ctor_set(x_36, 1, x_12); +return x_36; +} +} +} +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__4(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6, lean_object* x_7, lean_object* x_8, lean_object* x_9, lean_object* x_10, lean_object* x_11, lean_object* x_12) { +_start: +{ +lean_object* x_13; uint8_t x_14; +x_13 = lean_ctor_get(x_2, 1); +x_14 = lean_nat_dec_le(x_13, x_4); +if (x_14 == 0) +{ +lean_object* x_15; uint8_t x_16; +x_15 = lean_unsigned_to_nat(0u); +x_16 = lean_nat_dec_eq(x_3, x_15); +if (x_16 == 0) +{ +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_37; lean_object* x_38; lean_object* x_39; lean_object* x_40; lean_object* x_41; lean_object* x_42; lean_object* x_43; lean_object* x_44; lean_object* x_45; lean_object* x_46; lean_object* x_47; +x_17 = lean_unsigned_to_nat(1u); +x_18 = lean_nat_sub(x_3, x_17); +lean_dec(x_3); +x_19 = lean_ctor_get(x_5, 0); +lean_inc(x_19); +x_20 = lean_ctor_get(x_5, 1); +lean_inc(x_20); +lean_dec(x_5); +x_21 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_10, x_11, x_12); +x_22 = lean_ctor_get(x_21, 0); +lean_inc(x_22); +x_23 = lean_ctor_get(x_21, 1); +lean_inc(x_23); +lean_dec(x_21); +x_24 = l_Lean_Elab_Term_getCurrMacroScope(x_6, x_7, x_8, x_9, x_10, x_11, x_23); +x_25 = lean_ctor_get(x_24, 1); +lean_inc(x_25); +lean_dec(x_24); +x_26 = l_Lean_Elab_Term_getMainModule___rarg(x_11, x_25); +x_27 = lean_ctor_get(x_26, 1); +lean_inc(x_27); +lean_dec(x_26); +x_28 = l_myMacro____x40_Init_Notation___hyg_14458____closed__14; +x_29 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_29, 0, x_22); +lean_ctor_set(x_29, 1, x_28); +lean_inc(x_1); +x_30 = lean_array_push(x_1, x_29); +x_31 = l_myMacro____x40_Init_Notation___hyg_14458____closed__13; +x_32 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_32, 0, x_31); +lean_ctor_set(x_32, 1, x_30); +x_33 = lean_array_push(x_19, x_32); +x_34 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_10, x_11, x_27); +x_35 = lean_ctor_get(x_34, 0); +lean_inc(x_35); +x_36 = lean_ctor_get(x_34, 1); +lean_inc(x_36); +lean_dec(x_34); +x_37 = l_Lean_Elab_Term_getCurrMacroScope(x_6, x_7, x_8, x_9, x_10, x_11, x_36); +x_38 = lean_ctor_get(x_37, 1); +lean_inc(x_38); +lean_dec(x_37); +x_39 = l_Lean_Elab_Term_getMainModule___rarg(x_11, x_38); +x_40 = lean_ctor_get(x_39, 1); +lean_inc(x_40); +lean_dec(x_39); +x_41 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_41, 0, x_35); +lean_ctor_set(x_41, 1, x_28); +lean_inc(x_1); +x_42 = lean_array_push(x_1, x_41); +x_43 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_43, 0, x_31); +lean_ctor_set(x_43, 1, x_42); +x_44 = lean_array_push(x_20, x_43); +x_45 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_45, 0, x_33); +lean_ctor_set(x_45, 1, x_44); +x_46 = lean_ctor_get(x_2, 2); +x_47 = lean_nat_add(x_4, x_46); +lean_dec(x_4); +x_3 = x_18; +x_4 = x_47; +x_5 = x_45; +x_12 = x_40; +goto _start; +} +else +{ +lean_object* x_49; +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_1); +x_49 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_49, 0, x_5); +lean_ctor_set(x_49, 1, x_12); +return x_49; +} +} +else +{ +lean_object* x_50; +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_1); +x_50 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_50, 0, x_5); +lean_ctor_set(x_50, 1, x_12); +return x_50; +} +} +} +static lean_object* _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__1() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = lean_box(0); +x_2 = l_IO_Prim_fopenFlags___closed__4; +x_3 = lean_name_mk_string(x_1, x_2); +return x_3; +} +} +static lean_object* _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__2() { +_start: +{ +lean_object* x_1; +x_1 = lean_mk_string("compare"); +return x_1; +} +} +static lean_object* _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__3() { +_start: +{ +lean_object* x_1; lean_object* x_2; +x_1 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__2; +x_2 = lean_string_utf8_byte_size(x_1); +return x_2; +} +} +static lean_object* _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__4() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; +x_1 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__2; +x_2 = lean_unsigned_to_nat(0u); +x_3 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__3; +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_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__5() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = lean_box(0); +x_2 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__2; +x_3 = lean_name_mk_string(x_1, x_2); +return x_3; +} +} +static lean_object* _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__6() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg___closed__2; +x_2 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__2; +x_3 = lean_name_mk_string(x_1, x_2); +return x_3; +} +} +static lean_object* _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__7() { +_start: +{ +lean_object* x_1; +x_1 = lean_mk_string("Ordering.lt"); +return x_1; +} +} +static lean_object* _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__8() { +_start: +{ +lean_object* x_1; lean_object* x_2; +x_1 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__7; +x_2 = lean_string_utf8_byte_size(x_1); +return x_2; +} +} +static lean_object* _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__9() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; +x_1 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__7; +x_2 = lean_unsigned_to_nat(0u); +x_3 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__8; +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_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__10() { +_start: +{ +lean_object* x_1; +x_1 = lean_mk_string("lt"); +return x_1; +} +} +static lean_object* _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__11() { +_start: +{ +lean_object* x_1; +x_1 = lean_mk_string("Ordering.gt"); +return x_1; +} +} +static lean_object* _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__12() { +_start: +{ +lean_object* x_1; lean_object* x_2; +x_1 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__11; +x_2 = lean_string_utf8_byte_size(x_1); +return x_2; +} +} +static lean_object* _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__13() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; +x_1 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__11; +x_2 = lean_unsigned_to_nat(0u); +x_3 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__12; +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_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__14() { +_start: +{ +lean_object* x_1; +x_1 = lean_mk_string("gt"); +return x_1; +} +} +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6, lean_object* x_7, lean_object* x_8, lean_object* x_9, lean_object* x_10, lean_object* x_11, lean_object* x_12, lean_object* x_13, 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) { +_start: +{ +lean_object* x_22; uint8_t x_23; +x_22 = lean_ctor_get(x_11, 1); +x_23 = lean_nat_dec_le(x_22, x_13); +if (x_23 == 0) +{ +lean_object* x_24; uint8_t x_25; +x_24 = lean_unsigned_to_nat(0u); +x_25 = lean_nat_dec_eq(x_12, x_24); +if (x_25 == 0) +{ +lean_object* x_26; lean_object* x_27; lean_object* x_28; lean_object* x_29; lean_object* x_35; lean_object* x_36; lean_object* x_37; lean_object* x_38; lean_object* x_39; lean_object* x_40; lean_object* x_41; lean_object* x_60; lean_object* x_61; lean_object* x_62; lean_object* x_63; +x_26 = lean_unsigned_to_nat(1u); +x_27 = lean_nat_sub(x_12, x_26); +lean_dec(x_12); +x_35 = lean_ctor_get(x_14, 1); +lean_inc(x_35); +x_36 = lean_ctor_get(x_14, 0); +lean_inc(x_36); +lean_dec(x_14); +x_37 = lean_ctor_get(x_35, 0); +lean_inc(x_37); +x_38 = lean_ctor_get(x_35, 1); +lean_inc(x_38); +if (lean_is_exclusive(x_35)) { + lean_ctor_release(x_35, 0); + lean_ctor_release(x_35, 1); + x_39 = x_35; +} else { + lean_dec_ref(x_35); + x_39 = lean_box(0); +} +x_60 = lean_nat_add(x_10, x_13); +x_61 = l_Lean_instInhabitedExpr; +x_62 = lean_array_get(x_61, x_2, x_60); +lean_dec(x_60); +lean_inc(x_20); +lean_inc(x_19); +lean_inc(x_18); +lean_inc(x_17); +lean_inc(x_62); +x_63 = l_Lean_Meta_inferType(x_62, x_17, x_18, x_19, x_20, x_21); +if (lean_obj_tag(x_63) == 0) +{ +lean_object* x_64; lean_object* x_65; lean_object* x_66; +x_64 = lean_ctor_get(x_63, 0); +lean_inc(x_64); +x_65 = lean_ctor_get(x_63, 1); +lean_inc(x_65); +lean_dec(x_63); +lean_inc(x_20); +lean_inc(x_19); +lean_inc(x_18); +lean_inc(x_17); +x_66 = l_Lean_Meta_isProp(x_64, x_17, x_18, x_19, x_20, x_65); +if (lean_obj_tag(x_66) == 0) +{ +lean_object* x_67; lean_object* x_68; lean_object* x_69; uint8_t x_70; +x_67 = lean_ctor_get(x_66, 0); +lean_inc(x_67); +x_68 = lean_ctor_get(x_66, 1); +lean_inc(x_68); +lean_dec(x_66); +x_69 = l_Lean_Expr_fvarId_x21(x_62); +lean_dec(x_62); +x_70 = l_Lean_Expr_hasAnyFVar_visit___at_Lean_Expr_containsFVar___spec__1(x_69, x_3); +lean_dec(x_69); +if (x_70 == 0) +{ +uint8_t x_71; +x_71 = lean_unbox(x_67); +lean_dec(x_67); +if (x_71 == 0) +{ +lean_object* x_72; lean_object* x_73; lean_object* x_74; lean_object* x_75; lean_object* x_76; lean_object* x_77; lean_object* x_78; lean_object* x_79; lean_object* x_80; lean_object* x_81; lean_object* x_82; lean_object* x_83; lean_object* x_84; lean_object* x_85; lean_object* x_86; lean_object* x_87; lean_object* x_88; lean_object* x_89; lean_object* x_90; lean_object* x_91; lean_object* x_92; lean_object* x_93; lean_object* x_94; lean_object* x_95; lean_object* x_96; lean_object* x_97; lean_object* x_98; lean_object* x_99; lean_object* x_100; lean_object* x_101; lean_object* x_102; lean_object* x_103; lean_object* x_104; lean_object* x_105; lean_object* x_106; lean_object* x_107; lean_object* x_108; 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; 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; 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; lean_object* x_134; lean_object* x_135; lean_object* x_136; lean_object* x_137; lean_object* x_138; lean_object* x_139; lean_object* x_140; lean_object* x_141; lean_object* x_142; lean_object* x_143; lean_object* x_144; lean_object* x_145; lean_object* x_146; lean_object* x_147; lean_object* x_148; lean_object* x_149; lean_object* x_150; lean_object* x_151; lean_object* x_152; lean_object* x_153; lean_object* x_154; lean_object* x_155; lean_object* x_156; lean_object* x_157; lean_object* x_158; lean_object* x_159; lean_object* x_160; lean_object* x_161; lean_object* x_162; lean_object* x_163; lean_object* x_164; lean_object* x_165; lean_object* x_166; lean_object* x_167; lean_object* x_168; lean_object* x_169; lean_object* x_170; lean_object* x_171; lean_object* x_172; lean_object* x_173; lean_object* x_174; lean_object* x_175; +lean_dec(x_39); +x_72 = l_Array_myMacro____x40_Init_Data_Array_Subarray___hyg_936____closed__4; +x_73 = l___private_Lean_CoreM_0__Lean_Core_mkFreshNameImp(x_72, x_19, x_20, x_68); +x_74 = lean_ctor_get(x_73, 0); +lean_inc(x_74); +x_75 = lean_ctor_get(x_73, 1); +lean_inc(x_75); +lean_dec(x_73); +x_76 = lean_mk_syntax_ident(x_74); +x_77 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__1; +x_78 = l___private_Lean_CoreM_0__Lean_Core_mkFreshNameImp(x_77, x_19, x_20, x_75); +x_79 = lean_ctor_get(x_78, 0); +lean_inc(x_79); +x_80 = lean_ctor_get(x_78, 1); +lean_inc(x_80); +lean_dec(x_78); +x_81 = lean_mk_syntax_ident(x_79); +lean_inc(x_76); +x_82 = lean_array_push(x_36, x_76); +lean_inc(x_81); +x_83 = lean_array_push(x_37, x_81); +x_84 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_19, x_20, x_80); +x_85 = lean_ctor_get(x_84, 0); +lean_inc(x_85); +x_86 = lean_ctor_get(x_84, 1); +lean_inc(x_86); +lean_dec(x_84); +x_87 = l_Lean_Elab_Term_getCurrMacroScope(x_15, x_16, x_17, x_18, x_19, x_20, x_86); +x_88 = lean_ctor_get(x_87, 0); +lean_inc(x_88); +x_89 = lean_ctor_get(x_87, 1); +lean_inc(x_89); +lean_dec(x_87); +x_90 = l_Lean_Elab_Term_getMainModule___rarg(x_20, x_89); +x_91 = lean_ctor_get(x_90, 0); +lean_inc(x_91); +x_92 = lean_ctor_get(x_90, 1); +lean_inc(x_92); +lean_dec(x_90); +x_93 = l_myMacro____x40_Init_Notation___hyg_14458____closed__1; +lean_inc(x_85); +x_94 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_94, 0, x_85); +lean_ctor_set(x_94, 1, x_93); +lean_inc(x_1); +x_95 = lean_array_push(x_1, x_94); +x_96 = l_Lean_nullKind___closed__2; +lean_inc(x_1); +x_97 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_97, 0, x_96); +lean_ctor_set(x_97, 1, x_1); +lean_inc(x_97); +lean_inc(x_1); +x_98 = lean_array_push(x_1, x_97); +x_99 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__5; +lean_inc(x_88); +lean_inc(x_91); +x_100 = l_Lean_addMacroScope(x_91, x_99, x_88); +x_101 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__6; +lean_inc(x_7); +x_102 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_102, 0, x_101); +lean_ctor_set(x_102, 1, x_7); +lean_inc(x_8); +x_103 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_103, 0, x_102); +lean_ctor_set(x_103, 1, x_8); +x_104 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__4; +lean_inc(x_85); +x_105 = lean_alloc_ctor(3, 4, 0); +lean_ctor_set(x_105, 0, x_85); +lean_ctor_set(x_105, 1, x_104); +lean_ctor_set(x_105, 2, x_100); +lean_ctor_set(x_105, 3, x_103); +lean_inc(x_1); +x_106 = lean_array_push(x_1, x_105); +lean_inc(x_1); +x_107 = lean_array_push(x_1, x_76); +x_108 = lean_array_push(x_107, x_81); +x_109 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_109, 0, x_96); +lean_ctor_set(x_109, 1, x_108); +x_110 = lean_array_push(x_106, x_109); +x_111 = l_myMacro____x40_Init_Notation___hyg_2278____closed__4; +x_112 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_112, 0, x_111); +lean_ctor_set(x_112, 1, x_110); +x_113 = lean_array_push(x_98, x_112); +x_114 = l_myMacro____x40_Init_Notation___hyg_14458____closed__4; +x_115 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_115, 0, x_114); +lean_ctor_set(x_115, 1, x_113); +lean_inc(x_1); +x_116 = lean_array_push(x_1, x_115); +x_117 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_117, 0, x_96); +lean_ctor_set(x_117, 1, x_116); +x_118 = lean_array_push(x_95, x_117); +x_119 = lean_array_push(x_118, x_97); +x_120 = l_myMacro____x40_Init_Notation___hyg_14458____closed__6; +lean_inc(x_85); +x_121 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_121, 0, x_85); +lean_ctor_set(x_121, 1, x_120); +x_122 = lean_array_push(x_119, x_121); +x_123 = l_myMacro____x40_Init_Notation___hyg_14458____closed__11; +lean_inc(x_85); +x_124 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_124, 0, x_85); +lean_ctor_set(x_124, 1, x_123); +lean_inc(x_1); +x_125 = lean_array_push(x_1, x_124); +x_126 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__10; +lean_inc(x_5); +x_127 = lean_name_mk_string(x_5, x_126); +lean_inc(x_88); +lean_inc(x_127); +lean_inc(x_91); +x_128 = l_Lean_addMacroScope(x_91, x_127, x_88); +lean_inc(x_7); +x_129 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_129, 0, x_127); +lean_ctor_set(x_129, 1, x_7); +lean_inc(x_8); +x_130 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_130, 0, x_129); +lean_ctor_set(x_130, 1, x_8); +x_131 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__9; +lean_inc(x_85); +x_132 = lean_alloc_ctor(3, 4, 0); +lean_ctor_set(x_132, 0, x_85); +lean_ctor_set(x_132, 1, x_131); +lean_ctor_set(x_132, 2, x_128); +lean_ctor_set(x_132, 3, x_130); +lean_inc(x_132); +lean_inc(x_1); +x_133 = lean_array_push(x_1, x_132); +x_134 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_134, 0, x_96); +lean_ctor_set(x_134, 1, x_133); +lean_inc(x_125); +x_135 = lean_array_push(x_125, x_134); +x_136 = l_myMacro____x40_Init_Notation___hyg_13856____closed__13; +lean_inc(x_85); +x_137 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_137, 0, x_85); +lean_ctor_set(x_137, 1, x_136); +lean_inc(x_137); +x_138 = lean_array_push(x_135, x_137); +x_139 = lean_array_push(x_138, x_132); +x_140 = l_myMacro____x40_Init_Notation___hyg_14458____closed__10; +x_141 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_141, 0, x_140); +lean_ctor_set(x_141, 1, x_139); +lean_inc(x_1); +x_142 = lean_array_push(x_1, x_141); +x_143 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__14; +lean_inc(x_5); +x_144 = lean_name_mk_string(x_5, x_143); +lean_inc(x_88); +lean_inc(x_144); +lean_inc(x_91); +x_145 = l_Lean_addMacroScope(x_91, x_144, x_88); +lean_inc(x_7); +x_146 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_146, 0, x_144); +lean_ctor_set(x_146, 1, x_7); +lean_inc(x_8); +x_147 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_147, 0, x_146); +lean_ctor_set(x_147, 1, x_8); +x_148 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__13; +lean_inc(x_85); +x_149 = lean_alloc_ctor(3, 4, 0); +lean_ctor_set(x_149, 0, x_85); +lean_ctor_set(x_149, 1, x_148); +lean_ctor_set(x_149, 2, x_145); +lean_ctor_set(x_149, 3, x_147); +lean_inc(x_149); +lean_inc(x_1); +x_150 = lean_array_push(x_1, x_149); +x_151 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_151, 0, x_96); +lean_ctor_set(x_151, 1, x_150); +lean_inc(x_125); +x_152 = lean_array_push(x_125, x_151); +lean_inc(x_137); +x_153 = lean_array_push(x_152, x_137); +x_154 = lean_array_push(x_153, x_149); +x_155 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_155, 0, x_140); +lean_ctor_set(x_155, 1, x_154); +x_156 = lean_array_push(x_142, x_155); +lean_inc(x_6); +x_157 = l_Lean_addMacroScope(x_91, x_6, x_88); +lean_inc(x_9); +lean_inc(x_4); +x_158 = lean_alloc_ctor(3, 4, 0); +lean_ctor_set(x_158, 0, x_85); +lean_ctor_set(x_158, 1, x_4); +lean_ctor_set(x_158, 2, x_157); +lean_ctor_set(x_158, 3, x_9); +lean_inc(x_1); +x_159 = lean_array_push(x_1, x_158); +x_160 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_160, 0, x_96); +lean_ctor_set(x_160, 1, x_159); +x_161 = lean_array_push(x_125, x_160); +x_162 = lean_array_push(x_161, x_137); +x_163 = lean_array_push(x_162, x_38); +x_164 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_164, 0, x_140); +lean_ctor_set(x_164, 1, x_163); +x_165 = lean_array_push(x_156, x_164); +x_166 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_166, 0, x_96); +lean_ctor_set(x_166, 1, x_165); +lean_inc(x_1); +x_167 = lean_array_push(x_1, x_166); +x_168 = l_myMacro____x40_Init_Notation___hyg_14458____closed__8; +x_169 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_169, 0, x_168); +lean_ctor_set(x_169, 1, x_167); +x_170 = lean_array_push(x_122, x_169); +x_171 = l_myMacro____x40_Init_Notation___hyg_14458____closed__2; +x_172 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_172, 0, x_171); +lean_ctor_set(x_172, 1, x_170); +x_173 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_173, 0, x_83); +lean_ctor_set(x_173, 1, x_172); +x_174 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_174, 0, x_82); +lean_ctor_set(x_174, 1, x_173); +x_175 = lean_alloc_ctor(1, 1, 0); +lean_ctor_set(x_175, 0, x_174); +x_28 = x_175; +x_29 = x_92; +goto block_34; +} +else +{ +lean_object* x_176; lean_object* x_177; lean_object* x_178; lean_object* x_179; lean_object* x_180; lean_object* x_181; lean_object* x_182; lean_object* x_183; lean_object* x_184; lean_object* x_185; lean_object* x_186; lean_object* x_187; +x_176 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_19, x_20, x_68); +x_177 = lean_ctor_get(x_176, 0); +lean_inc(x_177); +x_178 = lean_ctor_get(x_176, 1); +lean_inc(x_178); +lean_dec(x_176); +x_179 = l_Lean_Elab_Term_getCurrMacroScope(x_15, x_16, x_17, x_18, x_19, x_20, x_178); +x_180 = lean_ctor_get(x_179, 1); +lean_inc(x_180); +lean_dec(x_179); +x_181 = l_Lean_Elab_Term_getMainModule___rarg(x_20, x_180); +x_182 = lean_ctor_get(x_181, 1); +lean_inc(x_182); +lean_dec(x_181); +x_183 = l_myMacro____x40_Init_Notation___hyg_14458____closed__14; +x_184 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_184, 0, x_177); +lean_ctor_set(x_184, 1, x_183); +lean_inc(x_1); +x_185 = lean_array_push(x_1, x_184); +x_186 = l_myMacro____x40_Init_Notation___hyg_14458____closed__13; +x_187 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_187, 0, x_186); +lean_ctor_set(x_187, 1, x_185); +x_40 = x_187; +x_41 = x_182; +goto block_59; +} +} +else +{ +lean_object* x_188; lean_object* x_189; lean_object* x_190; lean_object* x_191; lean_object* x_192; lean_object* x_193; lean_object* x_194; lean_object* x_195; lean_object* x_196; lean_object* x_197; lean_object* x_198; lean_object* x_199; +lean_dec(x_67); +x_188 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_19, x_20, x_68); +x_189 = lean_ctor_get(x_188, 0); +lean_inc(x_189); +x_190 = lean_ctor_get(x_188, 1); +lean_inc(x_190); +lean_dec(x_188); +x_191 = l_Lean_Elab_Term_getCurrMacroScope(x_15, x_16, x_17, x_18, x_19, x_20, x_190); +x_192 = lean_ctor_get(x_191, 1); +lean_inc(x_192); +lean_dec(x_191); +x_193 = l_Lean_Elab_Term_getMainModule___rarg(x_20, x_192); +x_194 = lean_ctor_get(x_193, 1); +lean_inc(x_194); +lean_dec(x_193); +x_195 = l_myMacro____x40_Init_Notation___hyg_14458____closed__14; +x_196 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_196, 0, x_189); +lean_ctor_set(x_196, 1, x_195); +lean_inc(x_1); +x_197 = lean_array_push(x_1, x_196); +x_198 = l_myMacro____x40_Init_Notation___hyg_14458____closed__13; +x_199 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_199, 0, x_198); +lean_ctor_set(x_199, 1, x_197); +x_40 = x_199; +x_41 = x_194; +goto block_59; +} +} +else +{ +uint8_t x_200; +lean_dec(x_62); +lean_dec(x_39); +lean_dec(x_38); +lean_dec(x_37); +lean_dec(x_36); +lean_dec(x_27); +lean_dec(x_20); +lean_dec(x_19); +lean_dec(x_18); +lean_dec(x_17); +lean_dec(x_13); +lean_dec(x_9); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_1); +x_200 = !lean_is_exclusive(x_66); +if (x_200 == 0) +{ +return x_66; +} +else +{ +lean_object* x_201; lean_object* x_202; lean_object* x_203; +x_201 = lean_ctor_get(x_66, 0); +x_202 = lean_ctor_get(x_66, 1); +lean_inc(x_202); +lean_inc(x_201); +lean_dec(x_66); +x_203 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_203, 0, x_201); +lean_ctor_set(x_203, 1, x_202); +return x_203; +} +} +} +else +{ +uint8_t x_204; +lean_dec(x_62); +lean_dec(x_39); +lean_dec(x_38); +lean_dec(x_37); +lean_dec(x_36); +lean_dec(x_27); +lean_dec(x_20); +lean_dec(x_19); +lean_dec(x_18); +lean_dec(x_17); +lean_dec(x_13); +lean_dec(x_9); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_1); +x_204 = !lean_is_exclusive(x_63); +if (x_204 == 0) +{ +return x_63; +} +else +{ +lean_object* x_205; lean_object* x_206; lean_object* x_207; +x_205 = lean_ctor_get(x_63, 0); +x_206 = lean_ctor_get(x_63, 1); +lean_inc(x_206); +lean_inc(x_205); +lean_dec(x_63); +x_207 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_207, 0, x_205); +lean_ctor_set(x_207, 1, x_206); +return x_207; +} +} +block_34: +{ +lean_object* x_30; lean_object* x_31; lean_object* x_32; +x_30 = lean_ctor_get(x_28, 0); +lean_inc(x_30); +lean_dec(x_28); +x_31 = lean_ctor_get(x_11, 2); +x_32 = lean_nat_add(x_13, x_31); +lean_dec(x_13); +x_12 = x_27; +x_13 = x_32; +x_14 = x_30; +x_21 = x_29; +goto _start; +} +block_59: +{ +lean_object* x_42; lean_object* x_43; lean_object* x_44; lean_object* x_45; lean_object* x_46; lean_object* x_47; lean_object* x_48; lean_object* x_49; lean_object* x_50; lean_object* x_51; lean_object* x_52; lean_object* x_53; lean_object* x_54; lean_object* x_55; lean_object* x_56; lean_object* x_57; lean_object* x_58; +x_42 = lean_array_push(x_36, x_40); +x_43 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_19, x_20, x_41); +x_44 = lean_ctor_get(x_43, 0); +lean_inc(x_44); +x_45 = lean_ctor_get(x_43, 1); +lean_inc(x_45); +lean_dec(x_43); +x_46 = l_Lean_Elab_Term_getCurrMacroScope(x_15, x_16, x_17, x_18, x_19, x_20, x_45); +x_47 = lean_ctor_get(x_46, 1); +lean_inc(x_47); +lean_dec(x_46); +x_48 = l_Lean_Elab_Term_getMainModule___rarg(x_20, x_47); +x_49 = lean_ctor_get(x_48, 1); +lean_inc(x_49); +lean_dec(x_48); +x_50 = l_myMacro____x40_Init_Notation___hyg_14458____closed__14; +x_51 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_51, 0, x_44); +lean_ctor_set(x_51, 1, x_50); +lean_inc(x_1); +x_52 = lean_array_push(x_1, x_51); +x_53 = l_myMacro____x40_Init_Notation___hyg_14458____closed__13; +x_54 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_54, 0, x_53); +lean_ctor_set(x_54, 1, x_52); +x_55 = lean_array_push(x_37, x_54); +if (lean_is_scalar(x_39)) { + x_56 = lean_alloc_ctor(0, 2, 0); +} else { + x_56 = x_39; +} +lean_ctor_set(x_56, 0, x_55); +lean_ctor_set(x_56, 1, x_38); +x_57 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_57, 0, x_42); +lean_ctor_set(x_57, 1, x_56); +x_58 = lean_alloc_ctor(1, 1, 0); +lean_ctor_set(x_58, 0, x_57); +x_28 = x_58; +x_29 = x_49; +goto block_34; +} +} +else +{ +lean_object* x_208; +lean_dec(x_20); +lean_dec(x_19); +lean_dec(x_18); +lean_dec(x_17); +lean_dec(x_13); +lean_dec(x_12); +lean_dec(x_9); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_1); +x_208 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_208, 0, x_14); +lean_ctor_set(x_208, 1, x_21); +return x_208; +} +} +else +{ +lean_object* x_209; +lean_dec(x_20); +lean_dec(x_19); +lean_dec(x_18); +lean_dec(x_17); +lean_dec(x_13); +lean_dec(x_12); +lean_dec(x_9); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_1); +x_209 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_209, 0, x_14); +lean_ctor_set(x_209, 1, x_21); +return x_209; +} +} +} +lean_object* l_Lean_Meta_forallTelescopeReducing___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__6___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, lean_object* x_9) { +_start: +{ +lean_object* x_10; lean_object* x_11; +x_10 = lean_alloc_closure((void*)(l_Lean_Meta_forallTelescope___at___private_Lean_Elab_Term_0__Lean_Elab_Term_tryPureCoe_x3f___spec__1___rarg___lambda__1), 10, 3); +lean_closure_set(x_10, 0, x_2); +lean_closure_set(x_10, 1, x_3); +lean_closure_set(x_10, 2, x_4); +x_11 = l___private_Lean_Meta_Basic_0__Lean_Meta_forallTelescopeReducingImp___rarg(x_1, x_10, x_5, x_6, x_7, x_8, x_9); +if (lean_obj_tag(x_11) == 0) +{ +uint8_t x_12; +x_12 = !lean_is_exclusive(x_11); +if (x_12 == 0) +{ +return x_11; +} +else +{ +lean_object* x_13; lean_object* x_14; lean_object* x_15; +x_13 = lean_ctor_get(x_11, 0); +x_14 = lean_ctor_get(x_11, 1); +lean_inc(x_14); +lean_inc(x_13); +lean_dec(x_11); +x_15 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_15, 0, x_13); +lean_ctor_set(x_15, 1, x_14); +return x_15; +} +} +else +{ +uint8_t x_16; +x_16 = !lean_is_exclusive(x_11); +if (x_16 == 0) +{ +return x_11; +} +else +{ +lean_object* x_17; lean_object* x_18; lean_object* x_19; +x_17 = lean_ctor_get(x_11, 0); +x_18 = lean_ctor_get(x_11, 1); +lean_inc(x_18); +lean_inc(x_17); +lean_dec(x_11); +x_19 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_19, 0, x_17); +lean_ctor_set(x_19, 1, x_18); +return x_19; +} +} +} +} +lean_object* l_Lean_Meta_forallTelescopeReducing___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__6(lean_object* x_1) { +_start: +{ +lean_object* x_2; +x_2 = lean_alloc_closure((void*)(l_Lean_Meta_forallTelescopeReducing___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__6___rarg), 9, 0); +return x_2; +} +} +static lean_object* _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__1() { +_start: +{ +lean_object* x_1; +x_1 = lean_mk_string("Ordering.eq"); +return x_1; +} +} +static lean_object* _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__2() { +_start: +{ +lean_object* x_1; lean_object* x_2; +x_1 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__1; +x_2 = lean_string_utf8_byte_size(x_1); +return x_2; +} +} +static lean_object* _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__3() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; +x_1 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__1; +x_2 = lean_unsigned_to_nat(0u); +x_3 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___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_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__4() { +_start: +{ +lean_object* x_1; +x_1 = lean_mk_string("Ordering"); +return x_1; +} +} +static lean_object* _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__5() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = lean_box(0); +x_2 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__4; +x_3 = lean_name_mk_string(x_1, x_2); +return x_3; +} +} +static lean_object* _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__6() { +_start: +{ +lean_object* x_1; +x_1 = lean_mk_string("eq"); +return x_1; +} +} +static lean_object* _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__7() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__5; +x_2 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__6; +x_3 = lean_name_mk_string(x_1, x_2); +return x_3; +} +} +static lean_object* _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__8() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = lean_box(0); +x_2 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__7; +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_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__9() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = lean_box(0); +x_2 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__8; +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_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__10() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__5; +x_2 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__10; +x_3 = lean_name_mk_string(x_1, x_2); +return x_3; +} +} +static lean_object* _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__11() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = lean_box(0); +x_2 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__10; +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_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__12() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = lean_box(0); +x_2 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__11; +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_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__13() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__5; +x_2 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__14; +x_3 = lean_name_mk_string(x_1, x_2); +return x_3; +} +} +static lean_object* _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__14() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = lean_box(0); +x_2 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__13; +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_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__15() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = lean_box(0); +x_2 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__14; +x_3 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_3, 0, x_2); +lean_ctor_set(x_3, 1, x_1); +return x_3; +} +} +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___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_object* x_8, lean_object* x_9, lean_object* x_10, lean_object* x_11, lean_object* x_12, lean_object* x_13) { +_start: +{ +lean_object* x_14; lean_object* x_15; lean_object* x_16; +x_14 = l_Lean_Core_betaReduce___closed__1; +x_15 = l_Lean_Core_betaReduce___closed__2; +lean_inc(x_12); +lean_inc(x_11); +x_16 = l_Lean_Core_transform___at_Lean_Core_betaReduce___spec__1(x_6, x_14, x_15, x_11, x_12, x_13); +if (lean_obj_tag(x_16) == 0) +{ +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_37; lean_object* x_38; lean_object* x_39; lean_object* x_40; lean_object* x_41; lean_object* x_42; lean_object* x_43; lean_object* x_44; lean_object* x_45; lean_object* x_46; uint8_t x_47; +x_17 = lean_ctor_get(x_16, 0); +lean_inc(x_17); +x_18 = lean_ctor_get(x_16, 1); +lean_inc(x_18); +lean_dec(x_16); +x_19 = lean_ctor_get(x_1, 1); +lean_inc(x_19); +x_20 = lean_ctor_get(x_1, 2); +lean_inc(x_20); +lean_dec(x_1); +x_21 = lean_unsigned_to_nat(0u); +x_22 = lean_unsigned_to_nat(1u); +lean_inc(x_20); +x_23 = lean_alloc_ctor(0, 3, 0); +lean_ctor_set(x_23, 0, x_21); +lean_ctor_set(x_23, 1, x_20); +lean_ctor_set(x_23, 2, x_22); +lean_inc_n(x_2, 2); +x_24 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__3(x_2, x_23, x_20, x_21, x_2, x_7, x_8, x_9, x_10, x_11, x_12, x_18); +lean_dec(x_23); +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_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_11, x_12, x_26); +x_28 = lean_ctor_get(x_27, 0); +lean_inc(x_28); +x_29 = lean_ctor_get(x_27, 1); +lean_inc(x_29); +lean_dec(x_27); +x_30 = l_Lean_Elab_Term_getCurrMacroScope(x_7, x_8, x_9, x_10, x_11, x_12, x_29); +x_31 = lean_ctor_get(x_30, 0); +lean_inc(x_31); +x_32 = lean_ctor_get(x_30, 1); +lean_inc(x_32); +lean_dec(x_30); +x_33 = l_Lean_Elab_Term_getMainModule___rarg(x_12, x_32); +x_34 = lean_ctor_get(x_33, 0); +lean_inc(x_34); +x_35 = lean_ctor_get(x_33, 1); +lean_inc(x_35); +lean_dec(x_33); +x_36 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__7; +x_37 = l_Lean_addMacroScope(x_34, x_36, x_31); +x_38 = lean_box(0); +x_39 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__3; +x_40 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__9; +x_41 = lean_alloc_ctor(3, 4, 0); +lean_ctor_set(x_41, 0, x_28); +lean_ctor_set(x_41, 1, x_39); +lean_ctor_set(x_41, 2, x_37); +lean_ctor_set(x_41, 3, x_40); +lean_inc(x_19); +x_42 = lean_alloc_ctor(0, 3, 0); +lean_ctor_set(x_42, 0, x_21); +lean_ctor_set(x_42, 1, x_19); +lean_ctor_set(x_42, 2, x_22); +lean_inc_n(x_2, 2); +x_43 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_43, 0, x_2); +lean_ctor_set(x_43, 1, x_2); +lean_inc(x_19); +lean_inc(x_2); +x_44 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__4(x_2, x_42, x_19, x_21, x_43, x_7, x_8, x_9, x_10, x_11, x_12, x_35); +lean_dec(x_42); +x_45 = lean_ctor_get(x_44, 0); +lean_inc(x_45); +x_46 = lean_ctor_get(x_44, 1); +lean_inc(x_46); +lean_dec(x_44); +x_47 = !lean_is_exclusive(x_45); +if (x_47 == 0) +{ +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; +x_48 = lean_ctor_get(x_45, 0); +x_49 = lean_ctor_get(x_45, 1); +x_50 = lean_ctor_get(x_3, 4); +lean_inc(x_50); +lean_dec(x_3); +lean_inc(x_50); +x_51 = lean_alloc_ctor(0, 3, 0); +lean_ctor_set(x_51, 0, x_21); +lean_ctor_set(x_51, 1, x_50); +lean_ctor_set(x_51, 2, x_22); +lean_ctor_set(x_45, 1, x_41); +lean_ctor_set(x_45, 0, x_49); +x_52 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_52, 0, x_48); +lean_ctor_set(x_52, 1, x_45); +x_53 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__5; +lean_inc(x_12); +lean_inc(x_11); +lean_inc(x_10); +lean_inc(x_9); +lean_inc(x_2); +x_54 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5(x_2, x_5, x_17, x_39, x_53, x_36, x_38, x_38, x_40, x_19, x_51, x_50, x_21, x_52, x_7, x_8, x_9, x_10, x_11, x_12, x_46); +lean_dec(x_51); +lean_dec(x_19); +lean_dec(x_17); +if (lean_obj_tag(x_54) == 0) +{ +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_65; lean_object* x_66; lean_object* x_67; lean_object* x_68; lean_object* x_69; lean_object* x_70; lean_object* x_71; lean_object* x_72; lean_object* x_73; lean_object* x_74; lean_object* x_75; lean_object* x_76; lean_object* x_77; lean_object* x_78; lean_object* x_79; lean_object* x_80; lean_object* x_81; lean_object* x_82; lean_object* x_83; lean_object* x_84; lean_object* x_85; lean_object* x_86; lean_object* x_87; lean_object* x_88; lean_object* x_89; lean_object* x_90; lean_object* x_91; lean_object* x_92; lean_object* x_93; lean_object* x_94; lean_object* x_95; lean_object* x_96; lean_object* x_97; lean_object* x_98; lean_object* x_99; lean_object* x_100; lean_object* x_101; lean_object* x_102; lean_object* x_103; lean_object* x_104; lean_object* x_105; lean_object* x_106; lean_object* x_107; lean_object* x_108; 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; 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; 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; lean_object* x_134; lean_object* x_135; lean_object* x_136; lean_object* x_137; lean_object* x_138; lean_object* x_139; lean_object* x_140; lean_object* x_141; size_t x_142; size_t x_143; lean_object* x_144; lean_object* x_145; lean_object* x_146; lean_object* x_147; lean_object* x_148; lean_object* x_149; lean_object* x_150; lean_object* x_151; lean_object* x_152; lean_object* x_153; lean_object* x_154; lean_object* x_155; lean_object* x_156; lean_object* x_157; lean_object* x_158; lean_object* x_159; lean_object* x_160; lean_object* x_161; lean_object* x_162; lean_object* x_163; lean_object* x_164; lean_object* x_165; lean_object* x_166; lean_object* x_167; lean_object* x_168; lean_object* x_169; size_t x_170; lean_object* x_171; lean_object* x_172; lean_object* x_173; lean_object* x_174; lean_object* x_175; lean_object* x_176; lean_object* x_177; lean_object* x_178; lean_object* x_179; lean_object* x_180; lean_object* x_181; lean_object* x_182; lean_object* x_183; lean_object* x_184; lean_object* x_185; lean_object* x_186; lean_object* x_187; lean_object* x_188; lean_object* x_189; lean_object* x_190; lean_object* x_191; lean_object* x_192; lean_object* x_193; uint8_t x_194; +x_55 = lean_ctor_get(x_54, 0); +lean_inc(x_55); +x_56 = lean_ctor_get(x_55, 1); +lean_inc(x_56); +x_57 = lean_ctor_get(x_54, 1); +lean_inc(x_57); +lean_dec(x_54); +x_58 = lean_ctor_get(x_55, 0); +lean_inc(x_58); +lean_dec(x_55); +x_59 = lean_ctor_get(x_56, 0); +lean_inc(x_59); +x_60 = lean_ctor_get(x_56, 1); +lean_inc(x_60); +lean_dec(x_56); +x_61 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_11, x_12, x_57); +x_62 = lean_ctor_get(x_61, 0); +lean_inc(x_62); +x_63 = lean_ctor_get(x_61, 1); +lean_inc(x_63); +lean_dec(x_61); +x_64 = l_Lean_Elab_Term_getCurrMacroScope(x_7, x_8, x_9, x_10, x_11, x_12, x_63); +x_65 = lean_ctor_get(x_64, 1); +lean_inc(x_65); +lean_dec(x_64); +x_66 = l_Lean_Elab_Term_getMainModule___rarg(x_12, x_65); +x_67 = lean_ctor_get(x_66, 1); +lean_inc(x_67); +lean_dec(x_66); +x_68 = l_Lean_Parser_Tactic_inductionAlt___closed__5; +x_69 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_69, 0, x_62); +lean_ctor_set(x_69, 1, x_68); +lean_inc(x_2); +x_70 = lean_array_push(x_2, x_69); +x_71 = lean_mk_syntax_ident(x_4); +lean_inc(x_71); +x_72 = lean_array_push(x_70, x_71); +x_73 = l_myMacro____x40_Init_NotationExtra___hyg_5662____closed__28; +x_74 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_74, 0, x_73); +lean_ctor_set(x_74, 1, x_72); +lean_inc(x_2); +x_75 = lean_array_push(x_2, x_74); +x_76 = l_Array_reverse___rarg(x_58); +lean_inc(x_2); +x_77 = l_Array_appendCore___rarg(x_2, x_76); +lean_dec(x_76); +x_78 = l_Lean_nullKind___closed__2; +x_79 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_79, 0, x_78); +lean_ctor_set(x_79, 1, x_77); +x_80 = lean_array_push(x_75, x_79); +x_81 = l_myMacro____x40_Init_Notation___hyg_2278____closed__4; +x_82 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_82, 0, x_81); +lean_ctor_set(x_82, 1, x_80); +x_83 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_11, x_12, x_67); +x_84 = lean_ctor_get(x_83, 0); +lean_inc(x_84); +x_85 = lean_ctor_get(x_83, 1); +lean_inc(x_85); +lean_dec(x_83); +x_86 = l_Lean_Elab_Term_getCurrMacroScope(x_7, x_8, x_9, x_10, x_11, x_12, x_85); +x_87 = lean_ctor_get(x_86, 1); +lean_inc(x_87); +lean_dec(x_86); +x_88 = l_Lean_Elab_Term_getMainModule___rarg(x_12, x_87); +x_89 = lean_ctor_get(x_88, 1); +lean_inc(x_89); +lean_dec(x_88); +x_90 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_90, 0, x_84); +lean_ctor_set(x_90, 1, x_68); +lean_inc(x_2); +x_91 = lean_array_push(x_2, x_90); +x_92 = lean_array_push(x_91, x_71); +x_93 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_93, 0, x_73); +lean_ctor_set(x_93, 1, x_92); +lean_inc(x_2); +x_94 = lean_array_push(x_2, x_93); +x_95 = l_Array_reverse___rarg(x_59); +lean_inc(x_2); +x_96 = l_Array_appendCore___rarg(x_2, x_95); +lean_dec(x_95); +x_97 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_97, 0, x_78); +lean_ctor_set(x_97, 1, x_96); +x_98 = lean_array_push(x_94, x_97); +x_99 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_99, 0, x_81); +lean_ctor_set(x_99, 1, x_98); +x_100 = l_Lean_Syntax_mkApp___closed__1; +x_101 = lean_array_push(x_100, x_82); +lean_inc(x_99); +lean_inc(x_101); +x_102 = lean_array_push(x_101, x_99); +lean_inc(x_25); +x_103 = l_Array_append___rarg(x_25, x_102); +lean_dec(x_102); +x_104 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_11, x_12, x_89); +x_105 = lean_ctor_get(x_104, 0); +lean_inc(x_105); +x_106 = lean_ctor_get(x_104, 1); +lean_inc(x_106); +lean_dec(x_104); +x_107 = l_Lean_Elab_Term_getCurrMacroScope(x_7, x_8, x_9, x_10, x_11, x_12, x_106); +x_108 = lean_ctor_get(x_107, 1); +lean_inc(x_108); +lean_dec(x_107); +x_109 = l_Lean_Elab_Term_getMainModule___rarg(x_12, x_108); +x_110 = lean_ctor_get(x_109, 1); +lean_inc(x_110); +lean_dec(x_109); +x_111 = l_myMacro____x40_Init_Notation___hyg_14458____closed__14; +x_112 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_112, 0, x_105); +lean_ctor_set(x_112, 1, x_111); +lean_inc(x_2); +x_113 = lean_array_push(x_2, x_112); +x_114 = l_myMacro____x40_Init_Notation___hyg_14458____closed__13; +x_115 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_115, 0, x_114); +lean_ctor_set(x_115, 1, x_113); +x_116 = lean_array_push(x_101, x_115); +lean_inc(x_25); +x_117 = l_Array_append___rarg(x_25, x_116); +lean_dec(x_116); +x_118 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_11, x_12, x_110); +x_119 = lean_ctor_get(x_118, 0); +lean_inc(x_119); +x_120 = lean_ctor_get(x_118, 1); +lean_inc(x_120); +lean_dec(x_118); +x_121 = l_Lean_Elab_Term_getCurrMacroScope(x_7, x_8, x_9, x_10, x_11, x_12, x_120); +x_122 = lean_ctor_get(x_121, 1); +lean_inc(x_122); +lean_dec(x_121); +x_123 = l_Lean_Elab_Term_getMainModule___rarg(x_12, x_122); +x_124 = lean_ctor_get(x_123, 1); +lean_inc(x_124); +lean_dec(x_123); +x_125 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_125, 0, x_119); +lean_ctor_set(x_125, 1, x_111); +lean_inc(x_2); +x_126 = lean_array_push(x_2, x_125); +x_127 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_127, 0, x_114); +lean_ctor_set(x_127, 1, x_126); +x_128 = lean_array_push(x_100, x_127); +x_129 = lean_array_push(x_128, x_99); +x_130 = l_Array_append___rarg(x_25, x_129); +lean_dec(x_129); +x_131 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_11, x_12, x_124); +x_132 = lean_ctor_get(x_131, 0); +lean_inc(x_132); +x_133 = lean_ctor_get(x_131, 1); +lean_inc(x_133); +lean_dec(x_131); +x_134 = l_Lean_Elab_Term_getCurrMacroScope(x_7, x_8, x_9, x_10, x_11, x_12, x_133); +x_135 = lean_ctor_get(x_134, 1); +lean_inc(x_135); +lean_dec(x_134); +x_136 = l_Lean_Elab_Term_getMainModule___rarg(x_12, x_135); +x_137 = lean_ctor_get(x_136, 1); +lean_inc(x_137); +lean_dec(x_136); +x_138 = l_myMacro____x40_Init_Notation___hyg_14458____closed__11; +lean_inc(x_132); +x_139 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_139, 0, x_132); +lean_ctor_set(x_139, 1, x_138); +lean_inc(x_2); +x_140 = lean_array_push(x_2, x_139); +x_141 = lean_array_get_size(x_103); +x_142 = lean_usize_of_nat(x_141); +lean_dec(x_141); +x_143 = 0; +x_144 = x_103; +x_145 = l_Array_mapMUnsafe_map___at_myMacro____x40_Init_NotationExtra___hyg_5201____spec__3(x_142, x_143, x_144); +x_146 = x_145; +x_147 = l_myMacro____x40_Init_NotationExtra___hyg_5201____closed__6; +x_148 = l_Lean_mkSepArray(x_146, x_147); +lean_dec(x_146); +lean_inc(x_2); +x_149 = l_Array_appendCore___rarg(x_2, x_148); +lean_dec(x_148); +x_150 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_150, 0, x_78); +lean_ctor_set(x_150, 1, x_149); +x_151 = lean_array_push(x_140, x_150); +x_152 = l_myMacro____x40_Init_Notation___hyg_13856____closed__13; +x_153 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_153, 0, x_132); +lean_ctor_set(x_153, 1, x_152); +x_154 = lean_array_push(x_151, x_153); +x_155 = lean_array_push(x_154, x_60); +x_156 = l_myMacro____x40_Init_Notation___hyg_14458____closed__10; +x_157 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_157, 0, x_156); +lean_ctor_set(x_157, 1, x_155); +x_158 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_11, x_12, x_137); +x_159 = lean_ctor_get(x_158, 0); +lean_inc(x_159); +x_160 = lean_ctor_get(x_158, 1); +lean_inc(x_160); +lean_dec(x_158); +x_161 = l_Lean_Elab_Term_getCurrMacroScope(x_7, x_8, x_9, x_10, x_11, x_12, x_160); +x_162 = lean_ctor_get(x_161, 0); +lean_inc(x_162); +x_163 = lean_ctor_get(x_161, 1); +lean_inc(x_163); +lean_dec(x_161); +x_164 = l_Lean_Elab_Term_getMainModule___rarg(x_12, x_163); +x_165 = lean_ctor_get(x_164, 0); +lean_inc(x_165); +x_166 = lean_ctor_get(x_164, 1); +lean_inc(x_166); +lean_dec(x_164); +lean_inc(x_159); +x_167 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_167, 0, x_159); +lean_ctor_set(x_167, 1, x_138); +lean_inc(x_2); +x_168 = lean_array_push(x_2, x_167); +x_169 = lean_array_get_size(x_117); +x_170 = lean_usize_of_nat(x_169); +lean_dec(x_169); +x_171 = x_117; +x_172 = l_Array_mapMUnsafe_map___at_myMacro____x40_Init_NotationExtra___hyg_5201____spec__3(x_170, x_143, x_171); +x_173 = x_172; +x_174 = l_Lean_mkSepArray(x_173, x_147); +lean_dec(x_173); +lean_inc(x_2); +x_175 = l_Array_appendCore___rarg(x_2, x_174); +lean_dec(x_174); +x_176 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_176, 0, x_78); +lean_ctor_set(x_176, 1, x_175); +x_177 = lean_array_push(x_168, x_176); +lean_inc(x_159); +x_178 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_178, 0, x_159); +lean_ctor_set(x_178, 1, x_152); +x_179 = lean_array_push(x_177, x_178); +x_180 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__10; +x_181 = l_Lean_addMacroScope(x_165, x_180, x_162); +x_182 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__9; +x_183 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__12; +x_184 = lean_alloc_ctor(3, 4, 0); +lean_ctor_set(x_184, 0, x_159); +lean_ctor_set(x_184, 1, x_182); +lean_ctor_set(x_184, 2, x_181); +lean_ctor_set(x_184, 3, x_183); +x_185 = lean_array_push(x_179, x_184); +x_186 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_186, 0, x_156); +lean_ctor_set(x_186, 1, x_185); +x_187 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_11, x_12, x_166); +x_188 = lean_ctor_get(x_187, 0); +lean_inc(x_188); +x_189 = lean_ctor_get(x_187, 1); +lean_inc(x_189); +lean_dec(x_187); +x_190 = l_Lean_Elab_Term_getCurrMacroScope(x_7, x_8, x_9, x_10, x_11, x_12, x_189); +lean_dec(x_11); +lean_dec(x_10); +lean_dec(x_9); +x_191 = lean_ctor_get(x_190, 0); +lean_inc(x_191); +x_192 = lean_ctor_get(x_190, 1); +lean_inc(x_192); +lean_dec(x_190); +x_193 = l_Lean_Elab_Term_getMainModule___rarg(x_12, x_192); +lean_dec(x_12); +x_194 = !lean_is_exclusive(x_193); +if (x_194 == 0) +{ +lean_object* x_195; lean_object* x_196; lean_object* x_197; lean_object* x_198; size_t x_199; lean_object* x_200; lean_object* x_201; lean_object* x_202; lean_object* x_203; lean_object* x_204; lean_object* x_205; lean_object* x_206; lean_object* x_207; lean_object* x_208; lean_object* x_209; lean_object* x_210; lean_object* x_211; lean_object* x_212; lean_object* x_213; lean_object* x_214; lean_object* x_215; lean_object* x_216; lean_object* x_217; lean_object* x_218; lean_object* x_219; +x_195 = lean_ctor_get(x_193, 0); +lean_inc(x_188); +x_196 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_196, 0, x_188); +lean_ctor_set(x_196, 1, x_138); +lean_inc(x_2); +x_197 = lean_array_push(x_2, x_196); +x_198 = lean_array_get_size(x_130); +x_199 = lean_usize_of_nat(x_198); +lean_dec(x_198); +x_200 = x_130; +x_201 = l_Array_mapMUnsafe_map___at_myMacro____x40_Init_NotationExtra___hyg_5201____spec__3(x_199, x_143, x_200); +x_202 = x_201; +x_203 = l_Lean_mkSepArray(x_202, x_147); +lean_dec(x_202); +x_204 = l_Array_appendCore___rarg(x_2, x_203); +lean_dec(x_203); +x_205 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_205, 0, x_78); +lean_ctor_set(x_205, 1, x_204); +x_206 = lean_array_push(x_197, x_205); +lean_inc(x_188); +x_207 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_207, 0, x_188); +lean_ctor_set(x_207, 1, x_152); +x_208 = lean_array_push(x_206, x_207); +x_209 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__13; +x_210 = l_Lean_addMacroScope(x_195, x_209, x_191); +x_211 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__13; +x_212 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__15; +x_213 = lean_alloc_ctor(3, 4, 0); +lean_ctor_set(x_213, 0, x_188); +lean_ctor_set(x_213, 1, x_211); +lean_ctor_set(x_213, 2, x_210); +lean_ctor_set(x_213, 3, x_212); +x_214 = lean_array_push(x_208, x_213); +x_215 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_215, 0, x_156); +lean_ctor_set(x_215, 1, x_214); +x_216 = l_Lean_Syntax_mkAntiquotNode___closed__9; +x_217 = lean_array_push(x_216, x_157); +x_218 = lean_array_push(x_217, x_186); +x_219 = lean_array_push(x_218, x_215); +lean_ctor_set(x_193, 0, x_219); +return x_193; +} +else +{ +lean_object* x_220; lean_object* x_221; lean_object* x_222; lean_object* x_223; lean_object* x_224; size_t x_225; lean_object* x_226; lean_object* x_227; lean_object* x_228; lean_object* x_229; lean_object* x_230; lean_object* x_231; lean_object* x_232; lean_object* x_233; lean_object* x_234; lean_object* x_235; lean_object* x_236; lean_object* x_237; lean_object* x_238; lean_object* x_239; lean_object* x_240; lean_object* x_241; lean_object* x_242; lean_object* x_243; lean_object* x_244; lean_object* x_245; lean_object* x_246; +x_220 = lean_ctor_get(x_193, 0); +x_221 = lean_ctor_get(x_193, 1); +lean_inc(x_221); +lean_inc(x_220); +lean_dec(x_193); +lean_inc(x_188); +x_222 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_222, 0, x_188); +lean_ctor_set(x_222, 1, x_138); +lean_inc(x_2); +x_223 = lean_array_push(x_2, x_222); +x_224 = lean_array_get_size(x_130); +x_225 = lean_usize_of_nat(x_224); +lean_dec(x_224); +x_226 = x_130; +x_227 = l_Array_mapMUnsafe_map___at_myMacro____x40_Init_NotationExtra___hyg_5201____spec__3(x_225, x_143, x_226); +x_228 = x_227; +x_229 = l_Lean_mkSepArray(x_228, x_147); +lean_dec(x_228); +x_230 = l_Array_appendCore___rarg(x_2, x_229); +lean_dec(x_229); +x_231 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_231, 0, x_78); +lean_ctor_set(x_231, 1, x_230); +x_232 = lean_array_push(x_223, x_231); +lean_inc(x_188); +x_233 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_233, 0, x_188); +lean_ctor_set(x_233, 1, x_152); +x_234 = lean_array_push(x_232, x_233); +x_235 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__13; +x_236 = l_Lean_addMacroScope(x_220, x_235, x_191); +x_237 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__13; +x_238 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__15; +x_239 = lean_alloc_ctor(3, 4, 0); +lean_ctor_set(x_239, 0, x_188); +lean_ctor_set(x_239, 1, x_237); +lean_ctor_set(x_239, 2, x_236); +lean_ctor_set(x_239, 3, x_238); +x_240 = lean_array_push(x_234, x_239); +x_241 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_241, 0, x_156); +lean_ctor_set(x_241, 1, x_240); +x_242 = l_Lean_Syntax_mkAntiquotNode___closed__9; +x_243 = lean_array_push(x_242, x_157); +x_244 = lean_array_push(x_243, x_186); +x_245 = lean_array_push(x_244, x_241); +x_246 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_246, 0, x_245); +lean_ctor_set(x_246, 1, x_221); +return x_246; +} +} +else +{ +uint8_t x_247; +lean_dec(x_25); +lean_dec(x_12); +lean_dec(x_11); +lean_dec(x_10); +lean_dec(x_9); +lean_dec(x_4); +lean_dec(x_2); +x_247 = !lean_is_exclusive(x_54); +if (x_247 == 0) +{ +return x_54; +} +else +{ +lean_object* x_248; lean_object* x_249; lean_object* x_250; +x_248 = lean_ctor_get(x_54, 0); +x_249 = lean_ctor_get(x_54, 1); +lean_inc(x_249); +lean_inc(x_248); +lean_dec(x_54); +x_250 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_250, 0, x_248); +lean_ctor_set(x_250, 1, x_249); +return x_250; +} +} +} +else +{ +lean_object* x_251; lean_object* x_252; lean_object* x_253; lean_object* x_254; lean_object* x_255; lean_object* x_256; lean_object* x_257; lean_object* x_258; +x_251 = lean_ctor_get(x_45, 0); +x_252 = lean_ctor_get(x_45, 1); +lean_inc(x_252); +lean_inc(x_251); +lean_dec(x_45); +x_253 = lean_ctor_get(x_3, 4); +lean_inc(x_253); +lean_dec(x_3); +lean_inc(x_253); +x_254 = lean_alloc_ctor(0, 3, 0); +lean_ctor_set(x_254, 0, x_21); +lean_ctor_set(x_254, 1, x_253); +lean_ctor_set(x_254, 2, x_22); +x_255 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_255, 0, x_252); +lean_ctor_set(x_255, 1, x_41); +x_256 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_256, 0, x_251); +lean_ctor_set(x_256, 1, x_255); +x_257 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__5; +lean_inc(x_12); +lean_inc(x_11); +lean_inc(x_10); +lean_inc(x_9); +lean_inc(x_2); +x_258 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5(x_2, x_5, x_17, x_39, x_257, x_36, x_38, x_38, x_40, x_19, x_254, x_253, x_21, x_256, x_7, x_8, x_9, x_10, x_11, x_12, x_46); +lean_dec(x_254); +lean_dec(x_19); +lean_dec(x_17); +if (lean_obj_tag(x_258) == 0) +{ +lean_object* x_259; lean_object* x_260; lean_object* x_261; lean_object* x_262; lean_object* x_263; lean_object* x_264; lean_object* x_265; lean_object* x_266; lean_object* x_267; lean_object* x_268; lean_object* x_269; lean_object* x_270; lean_object* x_271; lean_object* x_272; lean_object* x_273; lean_object* x_274; lean_object* x_275; lean_object* x_276; lean_object* x_277; lean_object* x_278; lean_object* x_279; lean_object* x_280; lean_object* x_281; lean_object* x_282; lean_object* x_283; lean_object* x_284; lean_object* x_285; lean_object* x_286; lean_object* x_287; lean_object* x_288; lean_object* x_289; lean_object* x_290; lean_object* x_291; lean_object* x_292; lean_object* x_293; lean_object* x_294; lean_object* x_295; lean_object* x_296; lean_object* x_297; lean_object* x_298; lean_object* x_299; lean_object* x_300; lean_object* x_301; lean_object* x_302; lean_object* x_303; lean_object* x_304; lean_object* x_305; lean_object* x_306; lean_object* x_307; lean_object* x_308; lean_object* x_309; lean_object* x_310; lean_object* x_311; lean_object* x_312; lean_object* x_313; lean_object* x_314; lean_object* x_315; lean_object* x_316; lean_object* x_317; lean_object* x_318; lean_object* x_319; lean_object* x_320; lean_object* x_321; lean_object* x_322; lean_object* x_323; lean_object* x_324; lean_object* x_325; lean_object* x_326; lean_object* x_327; lean_object* x_328; lean_object* x_329; lean_object* x_330; lean_object* x_331; lean_object* x_332; lean_object* x_333; lean_object* x_334; lean_object* x_335; lean_object* x_336; lean_object* x_337; lean_object* x_338; lean_object* x_339; lean_object* x_340; lean_object* x_341; lean_object* x_342; lean_object* x_343; lean_object* x_344; lean_object* x_345; size_t x_346; size_t x_347; lean_object* x_348; lean_object* x_349; lean_object* x_350; lean_object* x_351; lean_object* x_352; lean_object* x_353; lean_object* x_354; lean_object* x_355; lean_object* x_356; lean_object* x_357; lean_object* x_358; lean_object* x_359; lean_object* x_360; lean_object* x_361; lean_object* x_362; lean_object* x_363; lean_object* x_364; lean_object* x_365; lean_object* x_366; lean_object* x_367; lean_object* x_368; lean_object* x_369; lean_object* x_370; lean_object* x_371; lean_object* x_372; lean_object* x_373; size_t x_374; lean_object* x_375; lean_object* x_376; lean_object* x_377; lean_object* x_378; lean_object* x_379; lean_object* x_380; lean_object* x_381; lean_object* x_382; lean_object* x_383; lean_object* x_384; lean_object* x_385; lean_object* x_386; lean_object* x_387; lean_object* x_388; lean_object* x_389; lean_object* x_390; lean_object* x_391; lean_object* x_392; lean_object* x_393; lean_object* x_394; lean_object* x_395; lean_object* x_396; lean_object* x_397; lean_object* x_398; lean_object* x_399; lean_object* x_400; lean_object* x_401; lean_object* x_402; lean_object* x_403; size_t x_404; lean_object* x_405; lean_object* x_406; lean_object* x_407; lean_object* x_408; lean_object* x_409; lean_object* x_410; lean_object* x_411; lean_object* x_412; lean_object* x_413; lean_object* x_414; lean_object* x_415; lean_object* x_416; lean_object* x_417; lean_object* x_418; lean_object* x_419; lean_object* x_420; lean_object* x_421; lean_object* x_422; lean_object* x_423; lean_object* x_424; lean_object* x_425; +x_259 = lean_ctor_get(x_258, 0); +lean_inc(x_259); +x_260 = lean_ctor_get(x_259, 1); +lean_inc(x_260); +x_261 = lean_ctor_get(x_258, 1); +lean_inc(x_261); +lean_dec(x_258); +x_262 = lean_ctor_get(x_259, 0); +lean_inc(x_262); +lean_dec(x_259); +x_263 = lean_ctor_get(x_260, 0); +lean_inc(x_263); +x_264 = lean_ctor_get(x_260, 1); +lean_inc(x_264); +lean_dec(x_260); +x_265 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_11, x_12, x_261); +x_266 = lean_ctor_get(x_265, 0); +lean_inc(x_266); +x_267 = lean_ctor_get(x_265, 1); +lean_inc(x_267); +lean_dec(x_265); +x_268 = l_Lean_Elab_Term_getCurrMacroScope(x_7, x_8, x_9, x_10, x_11, x_12, x_267); +x_269 = lean_ctor_get(x_268, 1); +lean_inc(x_269); +lean_dec(x_268); +x_270 = l_Lean_Elab_Term_getMainModule___rarg(x_12, x_269); +x_271 = lean_ctor_get(x_270, 1); +lean_inc(x_271); +lean_dec(x_270); +x_272 = l_Lean_Parser_Tactic_inductionAlt___closed__5; +x_273 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_273, 0, x_266); +lean_ctor_set(x_273, 1, x_272); +lean_inc(x_2); +x_274 = lean_array_push(x_2, x_273); +x_275 = lean_mk_syntax_ident(x_4); +lean_inc(x_275); +x_276 = lean_array_push(x_274, x_275); +x_277 = l_myMacro____x40_Init_NotationExtra___hyg_5662____closed__28; +x_278 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_278, 0, x_277); +lean_ctor_set(x_278, 1, x_276); +lean_inc(x_2); +x_279 = lean_array_push(x_2, x_278); +x_280 = l_Array_reverse___rarg(x_262); +lean_inc(x_2); +x_281 = l_Array_appendCore___rarg(x_2, x_280); +lean_dec(x_280); +x_282 = l_Lean_nullKind___closed__2; +x_283 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_283, 0, x_282); +lean_ctor_set(x_283, 1, x_281); +x_284 = lean_array_push(x_279, x_283); +x_285 = l_myMacro____x40_Init_Notation___hyg_2278____closed__4; +x_286 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_286, 0, x_285); +lean_ctor_set(x_286, 1, x_284); +x_287 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_11, x_12, x_271); +x_288 = lean_ctor_get(x_287, 0); +lean_inc(x_288); +x_289 = lean_ctor_get(x_287, 1); +lean_inc(x_289); +lean_dec(x_287); +x_290 = l_Lean_Elab_Term_getCurrMacroScope(x_7, x_8, x_9, x_10, x_11, x_12, x_289); +x_291 = lean_ctor_get(x_290, 1); +lean_inc(x_291); +lean_dec(x_290); +x_292 = l_Lean_Elab_Term_getMainModule___rarg(x_12, x_291); +x_293 = lean_ctor_get(x_292, 1); +lean_inc(x_293); +lean_dec(x_292); +x_294 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_294, 0, x_288); +lean_ctor_set(x_294, 1, x_272); +lean_inc(x_2); +x_295 = lean_array_push(x_2, x_294); +x_296 = lean_array_push(x_295, x_275); +x_297 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_297, 0, x_277); +lean_ctor_set(x_297, 1, x_296); +lean_inc(x_2); +x_298 = lean_array_push(x_2, x_297); +x_299 = l_Array_reverse___rarg(x_263); +lean_inc(x_2); +x_300 = l_Array_appendCore___rarg(x_2, x_299); +lean_dec(x_299); +x_301 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_301, 0, x_282); +lean_ctor_set(x_301, 1, x_300); +x_302 = lean_array_push(x_298, x_301); +x_303 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_303, 0, x_285); +lean_ctor_set(x_303, 1, x_302); +x_304 = l_Lean_Syntax_mkApp___closed__1; +x_305 = lean_array_push(x_304, x_286); +lean_inc(x_303); +lean_inc(x_305); +x_306 = lean_array_push(x_305, x_303); +lean_inc(x_25); +x_307 = l_Array_append___rarg(x_25, x_306); +lean_dec(x_306); +x_308 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_11, x_12, x_293); +x_309 = lean_ctor_get(x_308, 0); +lean_inc(x_309); +x_310 = lean_ctor_get(x_308, 1); +lean_inc(x_310); +lean_dec(x_308); +x_311 = l_Lean_Elab_Term_getCurrMacroScope(x_7, x_8, x_9, x_10, x_11, x_12, x_310); +x_312 = lean_ctor_get(x_311, 1); +lean_inc(x_312); +lean_dec(x_311); +x_313 = l_Lean_Elab_Term_getMainModule___rarg(x_12, x_312); +x_314 = lean_ctor_get(x_313, 1); +lean_inc(x_314); +lean_dec(x_313); +x_315 = l_myMacro____x40_Init_Notation___hyg_14458____closed__14; +x_316 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_316, 0, x_309); +lean_ctor_set(x_316, 1, x_315); +lean_inc(x_2); +x_317 = lean_array_push(x_2, x_316); +x_318 = l_myMacro____x40_Init_Notation___hyg_14458____closed__13; +x_319 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_319, 0, x_318); +lean_ctor_set(x_319, 1, x_317); +x_320 = lean_array_push(x_305, x_319); +lean_inc(x_25); +x_321 = l_Array_append___rarg(x_25, x_320); +lean_dec(x_320); +x_322 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_11, x_12, x_314); +x_323 = lean_ctor_get(x_322, 0); +lean_inc(x_323); +x_324 = lean_ctor_get(x_322, 1); +lean_inc(x_324); +lean_dec(x_322); +x_325 = l_Lean_Elab_Term_getCurrMacroScope(x_7, x_8, x_9, x_10, x_11, x_12, x_324); +x_326 = lean_ctor_get(x_325, 1); +lean_inc(x_326); +lean_dec(x_325); +x_327 = l_Lean_Elab_Term_getMainModule___rarg(x_12, x_326); +x_328 = lean_ctor_get(x_327, 1); +lean_inc(x_328); +lean_dec(x_327); +x_329 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_329, 0, x_323); +lean_ctor_set(x_329, 1, x_315); +lean_inc(x_2); +x_330 = lean_array_push(x_2, x_329); +x_331 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_331, 0, x_318); +lean_ctor_set(x_331, 1, x_330); +x_332 = lean_array_push(x_304, x_331); +x_333 = lean_array_push(x_332, x_303); +x_334 = l_Array_append___rarg(x_25, x_333); +lean_dec(x_333); +x_335 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_11, x_12, x_328); +x_336 = lean_ctor_get(x_335, 0); +lean_inc(x_336); +x_337 = lean_ctor_get(x_335, 1); +lean_inc(x_337); +lean_dec(x_335); +x_338 = l_Lean_Elab_Term_getCurrMacroScope(x_7, x_8, x_9, x_10, x_11, x_12, x_337); +x_339 = lean_ctor_get(x_338, 1); +lean_inc(x_339); +lean_dec(x_338); +x_340 = l_Lean_Elab_Term_getMainModule___rarg(x_12, x_339); +x_341 = lean_ctor_get(x_340, 1); +lean_inc(x_341); +lean_dec(x_340); +x_342 = l_myMacro____x40_Init_Notation___hyg_14458____closed__11; +lean_inc(x_336); +x_343 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_343, 0, x_336); +lean_ctor_set(x_343, 1, x_342); +lean_inc(x_2); +x_344 = lean_array_push(x_2, x_343); +x_345 = lean_array_get_size(x_307); +x_346 = lean_usize_of_nat(x_345); +lean_dec(x_345); +x_347 = 0; +x_348 = x_307; +x_349 = l_Array_mapMUnsafe_map___at_myMacro____x40_Init_NotationExtra___hyg_5201____spec__3(x_346, x_347, x_348); +x_350 = x_349; +x_351 = l_myMacro____x40_Init_NotationExtra___hyg_5201____closed__6; +x_352 = l_Lean_mkSepArray(x_350, x_351); +lean_dec(x_350); +lean_inc(x_2); +x_353 = l_Array_appendCore___rarg(x_2, x_352); +lean_dec(x_352); +x_354 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_354, 0, x_282); +lean_ctor_set(x_354, 1, x_353); +x_355 = lean_array_push(x_344, x_354); +x_356 = l_myMacro____x40_Init_Notation___hyg_13856____closed__13; +x_357 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_357, 0, x_336); +lean_ctor_set(x_357, 1, x_356); +x_358 = lean_array_push(x_355, x_357); +x_359 = lean_array_push(x_358, x_264); +x_360 = l_myMacro____x40_Init_Notation___hyg_14458____closed__10; +x_361 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_361, 0, x_360); +lean_ctor_set(x_361, 1, x_359); +x_362 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_11, x_12, x_341); +x_363 = lean_ctor_get(x_362, 0); +lean_inc(x_363); +x_364 = lean_ctor_get(x_362, 1); +lean_inc(x_364); +lean_dec(x_362); +x_365 = l_Lean_Elab_Term_getCurrMacroScope(x_7, x_8, x_9, x_10, x_11, x_12, x_364); +x_366 = lean_ctor_get(x_365, 0); +lean_inc(x_366); +x_367 = lean_ctor_get(x_365, 1); +lean_inc(x_367); +lean_dec(x_365); +x_368 = l_Lean_Elab_Term_getMainModule___rarg(x_12, x_367); +x_369 = lean_ctor_get(x_368, 0); +lean_inc(x_369); +x_370 = lean_ctor_get(x_368, 1); +lean_inc(x_370); +lean_dec(x_368); +lean_inc(x_363); +x_371 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_371, 0, x_363); +lean_ctor_set(x_371, 1, x_342); +lean_inc(x_2); +x_372 = lean_array_push(x_2, x_371); +x_373 = lean_array_get_size(x_321); +x_374 = lean_usize_of_nat(x_373); +lean_dec(x_373); +x_375 = x_321; +x_376 = l_Array_mapMUnsafe_map___at_myMacro____x40_Init_NotationExtra___hyg_5201____spec__3(x_374, x_347, x_375); +x_377 = x_376; +x_378 = l_Lean_mkSepArray(x_377, x_351); +lean_dec(x_377); +lean_inc(x_2); +x_379 = l_Array_appendCore___rarg(x_2, x_378); +lean_dec(x_378); +x_380 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_380, 0, x_282); +lean_ctor_set(x_380, 1, x_379); +x_381 = lean_array_push(x_372, x_380); +lean_inc(x_363); +x_382 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_382, 0, x_363); +lean_ctor_set(x_382, 1, x_356); +x_383 = lean_array_push(x_381, x_382); +x_384 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__10; +x_385 = l_Lean_addMacroScope(x_369, x_384, x_366); +x_386 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__9; +x_387 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__12; +x_388 = lean_alloc_ctor(3, 4, 0); +lean_ctor_set(x_388, 0, x_363); +lean_ctor_set(x_388, 1, x_386); +lean_ctor_set(x_388, 2, x_385); +lean_ctor_set(x_388, 3, x_387); +x_389 = lean_array_push(x_383, x_388); +x_390 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_390, 0, x_360); +lean_ctor_set(x_390, 1, x_389); +x_391 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_11, x_12, x_370); +x_392 = lean_ctor_get(x_391, 0); +lean_inc(x_392); +x_393 = lean_ctor_get(x_391, 1); +lean_inc(x_393); +lean_dec(x_391); +x_394 = l_Lean_Elab_Term_getCurrMacroScope(x_7, x_8, x_9, x_10, x_11, x_12, x_393); +lean_dec(x_11); +lean_dec(x_10); +lean_dec(x_9); +x_395 = lean_ctor_get(x_394, 0); +lean_inc(x_395); +x_396 = lean_ctor_get(x_394, 1); +lean_inc(x_396); +lean_dec(x_394); +x_397 = l_Lean_Elab_Term_getMainModule___rarg(x_12, x_396); +lean_dec(x_12); +x_398 = lean_ctor_get(x_397, 0); +lean_inc(x_398); +x_399 = lean_ctor_get(x_397, 1); +lean_inc(x_399); +if (lean_is_exclusive(x_397)) { + lean_ctor_release(x_397, 0); + lean_ctor_release(x_397, 1); + x_400 = x_397; +} else { + lean_dec_ref(x_397); + x_400 = lean_box(0); +} +lean_inc(x_392); +x_401 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_401, 0, x_392); +lean_ctor_set(x_401, 1, x_342); +lean_inc(x_2); +x_402 = lean_array_push(x_2, x_401); +x_403 = lean_array_get_size(x_334); +x_404 = lean_usize_of_nat(x_403); +lean_dec(x_403); +x_405 = x_334; +x_406 = l_Array_mapMUnsafe_map___at_myMacro____x40_Init_NotationExtra___hyg_5201____spec__3(x_404, x_347, x_405); +x_407 = x_406; +x_408 = l_Lean_mkSepArray(x_407, x_351); +lean_dec(x_407); +x_409 = l_Array_appendCore___rarg(x_2, x_408); +lean_dec(x_408); +x_410 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_410, 0, x_282); +lean_ctor_set(x_410, 1, x_409); +x_411 = lean_array_push(x_402, x_410); +lean_inc(x_392); +x_412 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_412, 0, x_392); +lean_ctor_set(x_412, 1, x_356); +x_413 = lean_array_push(x_411, x_412); +x_414 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__13; +x_415 = l_Lean_addMacroScope(x_398, x_414, x_395); +x_416 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__13; +x_417 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__15; +x_418 = lean_alloc_ctor(3, 4, 0); +lean_ctor_set(x_418, 0, x_392); +lean_ctor_set(x_418, 1, x_416); +lean_ctor_set(x_418, 2, x_415); +lean_ctor_set(x_418, 3, x_417); +x_419 = lean_array_push(x_413, x_418); +x_420 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_420, 0, x_360); +lean_ctor_set(x_420, 1, x_419); +x_421 = l_Lean_Syntax_mkAntiquotNode___closed__9; +x_422 = lean_array_push(x_421, x_361); +x_423 = lean_array_push(x_422, x_390); +x_424 = lean_array_push(x_423, x_420); +if (lean_is_scalar(x_400)) { + x_425 = lean_alloc_ctor(0, 2, 0); +} else { + x_425 = x_400; +} +lean_ctor_set(x_425, 0, x_424); +lean_ctor_set(x_425, 1, x_399); +return x_425; +} +else +{ +lean_object* x_426; lean_object* x_427; lean_object* x_428; lean_object* x_429; +lean_dec(x_25); +lean_dec(x_12); +lean_dec(x_11); +lean_dec(x_10); +lean_dec(x_9); +lean_dec(x_4); +lean_dec(x_2); +x_426 = lean_ctor_get(x_258, 0); +lean_inc(x_426); +x_427 = lean_ctor_get(x_258, 1); +lean_inc(x_427); +if (lean_is_exclusive(x_258)) { + lean_ctor_release(x_258, 0); + lean_ctor_release(x_258, 1); + x_428 = x_258; +} else { + lean_dec_ref(x_258); + x_428 = lean_box(0); +} +if (lean_is_scalar(x_428)) { + x_429 = lean_alloc_ctor(1, 2, 0); +} else { + x_429 = x_428; +} +lean_ctor_set(x_429, 0, x_426); +lean_ctor_set(x_429, 1, x_427); +return x_429; +} +} +} +else +{ +uint8_t x_430; +lean_dec(x_12); +lean_dec(x_11); +lean_dec(x_10); +lean_dec(x_9); +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_2); +lean_dec(x_1); +x_430 = !lean_is_exclusive(x_16); +if (x_430 == 0) +{ +return x_16; +} +else +{ +lean_object* x_431; lean_object* x_432; lean_object* x_433; +x_431 = lean_ctor_get(x_16, 0); +x_432 = lean_ctor_get(x_16, 1); +lean_inc(x_432); +lean_inc(x_431); +lean_dec(x_16); +x_433 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_433, 0, x_431); +lean_ctor_set(x_433, 1, x_432); +return x_433; +} +} +} +} +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6, lean_object* x_7, lean_object* x_8, lean_object* x_9, lean_object* x_10, lean_object* x_11) { +_start: +{ +if (lean_obj_tag(x_3) == 0) +{ +lean_object* x_12; +lean_dec(x_10); +lean_dec(x_9); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_2); +lean_dec(x_1); +x_12 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_12, 0, x_4); +lean_ctor_set(x_12, 1, x_11); +return x_12; +} +else +{ +lean_object* x_13; lean_object* x_14; lean_object* x_15; +x_13 = lean_ctor_get(x_3, 0); +lean_inc(x_13); +x_14 = lean_ctor_get(x_3, 1); +lean_inc(x_14); +lean_dec(x_3); +lean_inc(x_5); +lean_inc(x_13); +x_15 = l_Lean_getConstInfoCtor___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__1(x_13, x_5, x_6, x_7, x_8, x_9, x_10, x_11); +if (lean_obj_tag(x_15) == 0) +{ +lean_object* x_16; lean_object* x_17; lean_object* x_18; lean_object* x_19; lean_object* x_20; lean_object* x_21; +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 = lean_ctor_get(x_16, 0); +lean_inc(x_18); +x_19 = lean_ctor_get(x_18, 2); +lean_inc(x_19); +lean_dec(x_18); +lean_inc(x_2); +lean_inc(x_1); +x_20 = lean_alloc_closure((void*)(l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___boxed), 13, 4); +lean_closure_set(x_20, 0, x_1); +lean_closure_set(x_20, 1, x_2); +lean_closure_set(x_20, 2, x_16); +lean_closure_set(x_20, 3, x_13); +lean_inc(x_10); +lean_inc(x_9); +lean_inc(x_8); +lean_inc(x_7); +lean_inc(x_6); +lean_inc(x_5); +x_21 = l_Lean_Meta_forallTelescopeReducing___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__6___rarg(x_19, x_20, x_5, x_6, x_7, x_8, x_9, x_10, x_17); +if (lean_obj_tag(x_21) == 0) +{ +lean_object* x_22; lean_object* x_23; lean_object* x_24; +x_22 = lean_ctor_get(x_21, 0); +lean_inc(x_22); +x_23 = lean_ctor_get(x_21, 1); +lean_inc(x_23); +lean_dec(x_21); +x_24 = l_Array_append___rarg(x_4, x_22); +lean_dec(x_22); +x_3 = x_14; +x_4 = x_24; +x_11 = x_23; +goto _start; +} +else +{ +uint8_t x_26; +lean_dec(x_14); +lean_dec(x_10); +lean_dec(x_9); +lean_dec(x_8); +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_26 = !lean_is_exclusive(x_21); +if (x_26 == 0) +{ +return x_21; +} +else +{ +lean_object* x_27; lean_object* x_28; lean_object* x_29; +x_27 = lean_ctor_get(x_21, 0); +x_28 = lean_ctor_get(x_21, 1); +lean_inc(x_28); +lean_inc(x_27); +lean_dec(x_21); +x_29 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_29, 0, x_27); +lean_ctor_set(x_29, 1, x_28); +return x_29; +} +} +} +else +{ +uint8_t x_30; +lean_dec(x_14); +lean_dec(x_13); +lean_dec(x_10); +lean_dec(x_9); +lean_dec(x_8); +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_30 = !lean_is_exclusive(x_15); +if (x_30 == 0) +{ +return x_15; +} +else +{ +lean_object* x_31; lean_object* x_32; lean_object* x_33; +x_31 = lean_ctor_get(x_15, 0); +x_32 = lean_ctor_get(x_15, 1); +lean_inc(x_32); +lean_inc(x_31); +lean_dec(x_15); +x_33 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_33, 0, x_31); +lean_ctor_set(x_33, 1, x_32); +return x_33; +} +} +} +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkMatch_mkAlts(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_object* x_10; lean_object* x_11; +x_9 = lean_ctor_get(x_1, 4); +lean_inc(x_9); +x_10 = l_Array_empty___closed__1; +x_11 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7(x_1, x_10, x_9, x_10, x_2, x_3, x_4, x_5, x_6, x_7, x_8); +if (lean_obj_tag(x_11) == 0) +{ +uint8_t x_12; +x_12 = !lean_is_exclusive(x_11); +if (x_12 == 0) +{ +lean_object* x_13; lean_object* x_14; lean_object* x_15; +x_13 = lean_ctor_get(x_11, 0); +x_14 = lean_array_pop(x_13); +x_15 = lean_array_pop(x_14); +lean_ctor_set(x_11, 0, x_15); +return x_11; +} +else +{ +lean_object* x_16; lean_object* x_17; lean_object* x_18; lean_object* x_19; lean_object* x_20; +x_16 = lean_ctor_get(x_11, 0); +x_17 = lean_ctor_get(x_11, 1); +lean_inc(x_17); +lean_inc(x_16); +lean_dec(x_11); +x_18 = lean_array_pop(x_16); +x_19 = lean_array_pop(x_18); +x_20 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_20, 0, x_19); +lean_ctor_set(x_20, 1, x_17); +return x_20; +} +} +else +{ +uint8_t x_21; +x_21 = !lean_is_exclusive(x_11); +if (x_21 == 0) +{ +return x_11; +} +else +{ +lean_object* x_22; lean_object* x_23; lean_object* x_24; +x_22 = lean_ctor_get(x_11, 0); +x_23 = lean_ctor_get(x_11, 1); +lean_inc(x_23); +lean_inc(x_22); +lean_dec(x_11); +x_24 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_24, 0, x_22); +lean_ctor_set(x_24, 1, x_23); +return x_24; +} +} +} +} +lean_object* l_Lean_throwError___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__2___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_throwError___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__2(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_3); +return x_9; +} +} +lean_object* l_Lean_getConstInfoCtor___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__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_object* x_8) { +_start: +{ +lean_object* x_9; +x_9 = l_Lean_getConstInfoCtor___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__1(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_3); +return x_9; +} +} +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__3___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, lean_object* x_9, lean_object* x_10, lean_object* x_11, lean_object* x_12) { +_start: +{ +lean_object* x_13; +x_13 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__3(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9, x_10, x_11, x_12); +lean_dec(x_11); +lean_dec(x_10); +lean_dec(x_9); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_2); +return x_13; +} +} +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__4___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, lean_object* x_9, lean_object* x_10, lean_object* x_11, lean_object* x_12) { +_start: +{ +lean_object* x_13; +x_13 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__4(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9, x_10, x_11, x_12); +lean_dec(x_11); +lean_dec(x_10); +lean_dec(x_9); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_2); +return x_13; +} +} +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___boxed(lean_object** _args) { +lean_object* x_1 = _args[0]; +lean_object* x_2 = _args[1]; +lean_object* x_3 = _args[2]; +lean_object* x_4 = _args[3]; +lean_object* x_5 = _args[4]; +lean_object* x_6 = _args[5]; +lean_object* x_7 = _args[6]; +lean_object* x_8 = _args[7]; +lean_object* x_9 = _args[8]; +lean_object* x_10 = _args[9]; +lean_object* x_11 = _args[10]; +lean_object* x_12 = _args[11]; +lean_object* x_13 = _args[12]; +lean_object* x_14 = _args[13]; +lean_object* x_15 = _args[14]; +lean_object* x_16 = _args[15]; +lean_object* x_17 = _args[16]; +lean_object* x_18 = _args[17]; +lean_object* x_19 = _args[18]; +lean_object* x_20 = _args[19]; +lean_object* x_21 = _args[20]; +_start: +{ +lean_object* x_22; +x_22 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9, x_10, x_11, x_12, x_13, x_14, x_15, x_16, x_17, x_18, x_19, x_20, x_21); +lean_dec(x_16); +lean_dec(x_15); +lean_dec(x_11); +lean_dec(x_10); +lean_dec(x_3); +lean_dec(x_2); +return x_22; +} +} +lean_object* l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___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_object* x_8, lean_object* x_9, lean_object* x_10, lean_object* x_11, lean_object* x_12, lean_object* x_13) { +_start: +{ +lean_object* x_14; +x_14 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9, x_10, x_11, x_12, x_13); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_5); +return x_14; +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkMatch___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, lean_object* x_9, lean_object* x_10) { +_start: +{ +lean_object* x_11; +lean_inc(x_9); +lean_inc(x_8); +lean_inc(x_7); +lean_inc(x_6); +lean_inc(x_5); +lean_inc(x_4); +lean_inc(x_2); +x_11 = l_Lean_Elab_Deriving_mkDiscrs(x_1, x_2, x_4, x_5, x_6, x_7, x_8, x_9, x_10); +if (lean_obj_tag(x_11) == 0) +{ +lean_object* x_12; lean_object* x_13; lean_object* x_14; +x_12 = lean_ctor_get(x_11, 0); +lean_inc(x_12); +x_13 = lean_ctor_get(x_11, 1); +lean_inc(x_13); +lean_dec(x_11); +lean_inc(x_9); +lean_inc(x_8); +lean_inc(x_7); +lean_inc(x_6); +lean_inc(x_5); +lean_inc(x_4); +x_14 = l_Lean_Elab_Deriving_Ord_mkMatch_mkAlts(x_2, x_4, x_5, x_6, x_7, x_8, x_9, x_13); +if (lean_obj_tag(x_14) == 0) +{ +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; uint8_t x_23; +x_15 = lean_ctor_get(x_14, 0); +lean_inc(x_15); +x_16 = lean_ctor_get(x_14, 1); +lean_inc(x_16); +lean_dec(x_14); +x_17 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInductiveApp___spec__2___rarg(x_8, x_9, x_16); +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_Elab_Term_getCurrMacroScope(x_4, x_5, x_6, x_7, x_8, x_9, x_19); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +x_21 = lean_ctor_get(x_20, 1); +lean_inc(x_21); +lean_dec(x_20); +x_22 = l_Lean_Elab_Term_getMainModule___rarg(x_9, x_21); +lean_dec(x_9); +x_23 = !lean_is_exclusive(x_22); +if (x_23 == 0) +{ +lean_object* x_24; lean_object* x_25; lean_object* x_26; lean_object* x_27; lean_object* x_28; lean_object* x_29; size_t x_30; size_t x_31; lean_object* x_32; lean_object* x_33; lean_object* x_34; lean_object* x_35; lean_object* x_36; lean_object* x_37; lean_object* x_38; lean_object* x_39; lean_object* x_40; lean_object* x_41; lean_object* x_42; lean_object* x_43; lean_object* x_44; lean_object* x_45; lean_object* x_46; lean_object* x_47; lean_object* x_48; lean_object* x_49; lean_object* x_50; lean_object* x_51; lean_object* x_52; lean_object* x_53; +x_24 = lean_ctor_get(x_22, 0); +lean_dec(x_24); +x_25 = l_myMacro____x40_Init_Notation___hyg_14458____closed__1; +lean_inc(x_18); +x_26 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_26, 0, x_18); +lean_ctor_set(x_26, 1, x_25); +x_27 = l_Array_empty___closed__1; +x_28 = lean_array_push(x_27, x_26); +x_29 = lean_array_get_size(x_12); +x_30 = lean_usize_of_nat(x_29); +lean_dec(x_29); +x_31 = 0; +x_32 = x_12; +x_33 = l_Array_mapMUnsafe_map___at_myMacro____x40_Init_NotationExtra___hyg_5201____spec__3(x_30, x_31, x_32); +x_34 = x_33; +x_35 = l_myMacro____x40_Init_NotationExtra___hyg_5201____closed__6; +x_36 = l_Lean_mkSepArray(x_34, x_35); +lean_dec(x_34); +x_37 = l_Array_appendCore___rarg(x_27, x_36); +lean_dec(x_36); +x_38 = l_Lean_nullKind___closed__2; +x_39 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_39, 0, x_38); +lean_ctor_set(x_39, 1, x_37); +x_40 = lean_array_push(x_28, x_39); +x_41 = l_myMacro____x40_Init_Notation___hyg_1481____closed__8; +x_42 = lean_array_push(x_40, x_41); +x_43 = l_myMacro____x40_Init_Notation___hyg_14458____closed__6; +x_44 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_44, 0, x_18); +lean_ctor_set(x_44, 1, x_43); +x_45 = lean_array_push(x_42, x_44); +x_46 = l_Array_appendCore___rarg(x_27, x_15); +lean_dec(x_15); +x_47 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_47, 0, x_38); +lean_ctor_set(x_47, 1, x_46); +x_48 = lean_array_push(x_27, x_47); +x_49 = l_myMacro____x40_Init_Notation___hyg_14458____closed__8; +x_50 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_50, 0, x_49); +lean_ctor_set(x_50, 1, x_48); +x_51 = lean_array_push(x_45, x_50); +x_52 = l_myMacro____x40_Init_Notation___hyg_14458____closed__2; +x_53 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_53, 0, x_52); +lean_ctor_set(x_53, 1, x_51); +lean_ctor_set(x_22, 0, x_53); +return x_22; +} +else +{ +lean_object* x_54; lean_object* x_55; lean_object* x_56; lean_object* x_57; lean_object* x_58; lean_object* x_59; size_t x_60; size_t x_61; lean_object* x_62; lean_object* x_63; lean_object* x_64; 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; lean_object* x_74; lean_object* x_75; lean_object* x_76; lean_object* x_77; lean_object* x_78; lean_object* x_79; lean_object* x_80; lean_object* x_81; lean_object* x_82; lean_object* x_83; lean_object* x_84; +x_54 = lean_ctor_get(x_22, 1); +lean_inc(x_54); +lean_dec(x_22); +x_55 = l_myMacro____x40_Init_Notation___hyg_14458____closed__1; +lean_inc(x_18); +x_56 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_56, 0, x_18); +lean_ctor_set(x_56, 1, x_55); +x_57 = l_Array_empty___closed__1; +x_58 = lean_array_push(x_57, x_56); +x_59 = lean_array_get_size(x_12); +x_60 = lean_usize_of_nat(x_59); +lean_dec(x_59); +x_61 = 0; +x_62 = x_12; +x_63 = l_Array_mapMUnsafe_map___at_myMacro____x40_Init_NotationExtra___hyg_5201____spec__3(x_60, x_61, x_62); +x_64 = x_63; +x_65 = l_myMacro____x40_Init_NotationExtra___hyg_5201____closed__6; +x_66 = l_Lean_mkSepArray(x_64, x_65); +lean_dec(x_64); +x_67 = l_Array_appendCore___rarg(x_57, x_66); +lean_dec(x_66); +x_68 = l_Lean_nullKind___closed__2; +x_69 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_69, 0, x_68); +lean_ctor_set(x_69, 1, x_67); +x_70 = lean_array_push(x_58, x_69); +x_71 = l_myMacro____x40_Init_Notation___hyg_1481____closed__8; +x_72 = lean_array_push(x_70, x_71); +x_73 = l_myMacro____x40_Init_Notation___hyg_14458____closed__6; +x_74 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_74, 0, x_18); +lean_ctor_set(x_74, 1, x_73); +x_75 = lean_array_push(x_72, x_74); +x_76 = l_Array_appendCore___rarg(x_57, x_15); +lean_dec(x_15); +x_77 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_77, 0, x_68); +lean_ctor_set(x_77, 1, x_76); +x_78 = lean_array_push(x_57, x_77); +x_79 = l_myMacro____x40_Init_Notation___hyg_14458____closed__8; +x_80 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_80, 0, x_79); +lean_ctor_set(x_80, 1, x_78); +x_81 = lean_array_push(x_75, x_80); +x_82 = l_myMacro____x40_Init_Notation___hyg_14458____closed__2; +x_83 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_83, 0, x_82); +lean_ctor_set(x_83, 1, x_81); +x_84 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_84, 0, x_83); +lean_ctor_set(x_84, 1, x_54); +return x_84; +} +} +else +{ +uint8_t x_85; +lean_dec(x_12); +lean_dec(x_9); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +x_85 = !lean_is_exclusive(x_14); +if (x_85 == 0) +{ +return x_14; +} +else +{ +lean_object* x_86; lean_object* x_87; lean_object* x_88; +x_86 = lean_ctor_get(x_14, 0); +x_87 = lean_ctor_get(x_14, 1); +lean_inc(x_87); +lean_inc(x_86); +lean_dec(x_14); +x_88 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_88, 0, x_86); +lean_ctor_set(x_88, 1, x_87); +return x_88; +} +} +} +else +{ +uint8_t x_89; +lean_dec(x_9); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_2); +x_89 = !lean_is_exclusive(x_11); +if (x_89 == 0) +{ +return x_11; +} +else +{ +lean_object* x_90; lean_object* x_91; lean_object* x_92; +x_90 = lean_ctor_get(x_11, 0); +x_91 = lean_ctor_get(x_11, 1); +lean_inc(x_91); +lean_inc(x_90); +lean_dec(x_11); +x_92 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_92, 0, x_90); +lean_ctor_set(x_92, 1, x_91); +return x_92; +} +} +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkMatch(lean_object* x_1) { +_start: +{ +lean_object* x_2; +x_2 = lean_alloc_closure((void*)(l_Lean_Elab_Deriving_Ord_mkMatch___rarg___boxed), 10, 0); +return x_2; +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkMatch___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, lean_object* x_9, lean_object* x_10) { +_start: +{ +lean_object* x_11; +x_11 = l_Lean_Elab_Deriving_Ord_mkMatch___rarg(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9, x_10); +lean_dec(x_3); +return x_11; +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkMatch___boxed(lean_object* x_1) { +_start: +{ +lean_object* x_2; +x_2 = l_Lean_Elab_Deriving_Ord_mkMatch(x_1); +lean_dec(x_1); +return x_2; +} +} +static lean_object* _init_l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__1() { +_start: +{ +lean_object* x_1; lean_object* x_2; +x_1 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__4; +x_2 = lean_string_utf8_byte_size(x_1); +return x_2; +} +} +static lean_object* _init_l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__2() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; lean_object* x_4; +x_1 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__4; +x_2 = lean_unsigned_to_nat(0u); +x_3 = l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__1; +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_Deriving_Ord_mkAuxFunction___lambda__1___closed__3() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = lean_box(0); +x_2 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__5; +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_Deriving_Ord_mkAuxFunction___lambda__1___closed__4() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = lean_box(0); +x_2 = l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__3; +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; +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkAuxFunction___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_object* x_8, lean_object* x_9, lean_object* x_10, lean_object* x_11, lean_object* x_12, lean_object* x_13) { +_start: +{ +lean_object* x_14; lean_object* x_15; uint8_t x_163; +x_14 = lean_ctor_get(x_1, 0); +x_163 = lean_ctor_get_uint8(x_3, sizeof(void*)*2); +if (x_163 == 0) +{ +uint8_t x_164; +x_164 = lean_ctor_get_uint8(x_4, sizeof(void*)*5); +if (x_164 == 0) +{ +lean_object* x_165; lean_object* x_166; lean_object* x_167; lean_object* x_168; lean_object* x_169; lean_object* x_170; lean_object* x_171; uint8_t x_172; +x_165 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_11, x_12, x_13); +x_166 = lean_ctor_get(x_165, 0); +lean_inc(x_166); +x_167 = lean_ctor_get(x_165, 1); +lean_inc(x_167); +lean_dec(x_165); +x_168 = l_Lean_Elab_Term_getCurrMacroScope(x_7, x_8, x_9, x_10, x_11, x_12, x_167); +x_169 = lean_ctor_get(x_168, 0); +lean_inc(x_169); +x_170 = lean_ctor_get(x_168, 1); +lean_inc(x_170); +lean_dec(x_168); +x_171 = l_Lean_Elab_Term_getMainModule___rarg(x_12, x_170); +x_172 = !lean_is_exclusive(x_171); +if (x_172 == 0) +{ +lean_object* x_173; lean_object* x_174; lean_object* x_175; lean_object* x_176; lean_object* x_177; lean_object* x_178; lean_object* x_179; lean_object* x_180; lean_object* x_181; lean_object* x_182; lean_object* x_183; lean_object* x_184; lean_object* x_185; lean_object* x_186; lean_object* x_187; lean_object* x_188; lean_object* x_189; lean_object* x_190; lean_object* x_191; lean_object* x_192; lean_object* x_193; lean_object* x_194; lean_object* x_195; lean_object* x_196; lean_object* x_197; lean_object* x_198; lean_object* x_199; lean_object* x_200; lean_object* x_201; lean_object* x_202; lean_object* x_203; lean_object* x_204; lean_object* x_205; lean_object* x_206; lean_object* x_207; lean_object* x_208; lean_object* x_209; lean_object* x_210; lean_object* x_211; lean_object* x_212; lean_object* x_213; lean_object* x_214; lean_object* x_215; lean_object* x_216; lean_object* x_217; lean_object* x_218; lean_object* x_219; lean_object* x_220; lean_object* x_221; lean_object* x_222; lean_object* x_223; lean_object* x_224; lean_object* x_225; lean_object* x_226; lean_object* x_227; lean_object* x_228; lean_object* x_229; lean_object* x_230; lean_object* x_231; lean_object* x_232; lean_object* x_233; +x_173 = lean_ctor_get(x_171, 0); +x_174 = l_Lean_Parser_Command_private___elambda__1___closed__1; +lean_inc(x_166); +x_175 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_175, 0, x_166); +lean_ctor_set(x_175, 1, x_174); +x_176 = l_Array_empty___closed__1; +x_177 = lean_array_push(x_176, x_175); +x_178 = l_Lean_Parser_Command_private___elambda__1___closed__2; +x_179 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_179, 0, x_178); +lean_ctor_set(x_179, 1, x_177); +x_180 = lean_array_push(x_176, x_179); +x_181 = l_Lean_nullKind___closed__2; +x_182 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_182, 0, x_181); +lean_ctor_set(x_182, 1, x_180); +x_183 = l_myMacro____x40_Init_NotationExtra___hyg_5662____closed__4; +x_184 = lean_array_push(x_183, x_182); +x_185 = l_myMacro____x40_Init_Notation___hyg_1481____closed__8; +x_186 = lean_array_push(x_184, x_185); +x_187 = lean_array_push(x_186, x_185); +x_188 = lean_array_push(x_187, x_185); +x_189 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__7; +x_190 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_190, 0, x_189); +lean_ctor_set(x_190, 1, x_188); +x_191 = lean_array_push(x_176, x_190); +x_192 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__20; +lean_inc(x_166); +x_193 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_193, 0, x_166); +lean_ctor_set(x_193, 1, x_192); +x_194 = lean_array_push(x_176, x_193); +x_195 = lean_mk_syntax_ident(x_2); +x_196 = lean_array_push(x_176, x_195); +x_197 = lean_array_push(x_196, x_185); +x_198 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__23; +x_199 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_199, 0, x_198); +lean_ctor_set(x_199, 1, x_197); +x_200 = lean_array_push(x_194, x_199); +x_201 = l_Array_appendCore___rarg(x_176, x_14); +x_202 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_202, 0, x_181); +lean_ctor_set(x_202, 1, x_201); +x_203 = lean_array_push(x_176, x_202); +x_204 = l_myMacro____x40_Init_Notation___hyg_15378____closed__9; +lean_inc(x_166); +x_205 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_205, 0, x_166); +lean_ctor_set(x_205, 1, x_204); +x_206 = lean_array_push(x_176, x_205); +x_207 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__5; +x_208 = l_Lean_addMacroScope(x_173, x_207, x_169); +x_209 = l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__2; +x_210 = l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__4; +lean_inc(x_166); +x_211 = lean_alloc_ctor(3, 4, 0); +lean_ctor_set(x_211, 0, x_166); +lean_ctor_set(x_211, 1, x_209); +lean_ctor_set(x_211, 2, x_208); +lean_ctor_set(x_211, 3, x_210); +x_212 = lean_array_push(x_206, x_211); +x_213 = l_Lean_expandExplicitBindersAux_loop___closed__4; +x_214 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_214, 0, x_213); +lean_ctor_set(x_214, 1, x_212); +x_215 = lean_array_push(x_176, x_214); +x_216 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_216, 0, x_181); +lean_ctor_set(x_216, 1, x_215); +x_217 = lean_array_push(x_203, x_216); +x_218 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__25; +x_219 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_219, 0, x_218); +lean_ctor_set(x_219, 1, x_217); +x_220 = lean_array_push(x_200, x_219); +x_221 = l_myMacro____x40_Init_Notation___hyg_15947____closed__11; +x_222 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_222, 0, x_166); +lean_ctor_set(x_222, 1, x_221); +x_223 = lean_array_push(x_176, x_222); +x_224 = lean_array_push(x_223, x_5); +x_225 = lean_array_push(x_224, x_185); +x_226 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__33; +x_227 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_227, 0, x_226); +lean_ctor_set(x_227, 1, x_225); +x_228 = lean_array_push(x_220, x_227); +x_229 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__21; +x_230 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_230, 0, x_229); +lean_ctor_set(x_230, 1, x_228); +x_231 = lean_array_push(x_191, x_230); +x_232 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__5; +x_233 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_233, 0, x_232); +lean_ctor_set(x_233, 1, x_231); +lean_ctor_set(x_171, 0, x_233); +return x_171; +} +else +{ +lean_object* x_234; lean_object* x_235; lean_object* x_236; lean_object* x_237; lean_object* x_238; lean_object* x_239; lean_object* x_240; lean_object* x_241; lean_object* x_242; lean_object* x_243; lean_object* x_244; lean_object* x_245; lean_object* x_246; lean_object* x_247; lean_object* x_248; lean_object* x_249; lean_object* x_250; lean_object* x_251; lean_object* x_252; lean_object* x_253; lean_object* x_254; lean_object* x_255; lean_object* x_256; lean_object* x_257; lean_object* x_258; lean_object* x_259; lean_object* x_260; lean_object* x_261; lean_object* x_262; lean_object* x_263; lean_object* x_264; lean_object* x_265; lean_object* x_266; lean_object* x_267; lean_object* x_268; lean_object* x_269; lean_object* x_270; lean_object* x_271; lean_object* x_272; lean_object* x_273; lean_object* x_274; lean_object* x_275; lean_object* x_276; lean_object* x_277; lean_object* x_278; lean_object* x_279; lean_object* x_280; lean_object* x_281; lean_object* x_282; lean_object* x_283; lean_object* x_284; lean_object* x_285; lean_object* x_286; lean_object* x_287; lean_object* x_288; lean_object* x_289; lean_object* x_290; lean_object* x_291; lean_object* x_292; lean_object* x_293; lean_object* x_294; lean_object* x_295; lean_object* x_296; +x_234 = lean_ctor_get(x_171, 0); +x_235 = lean_ctor_get(x_171, 1); +lean_inc(x_235); +lean_inc(x_234); +lean_dec(x_171); +x_236 = l_Lean_Parser_Command_private___elambda__1___closed__1; +lean_inc(x_166); +x_237 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_237, 0, x_166); +lean_ctor_set(x_237, 1, x_236); +x_238 = l_Array_empty___closed__1; +x_239 = lean_array_push(x_238, x_237); +x_240 = l_Lean_Parser_Command_private___elambda__1___closed__2; +x_241 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_241, 0, x_240); +lean_ctor_set(x_241, 1, x_239); +x_242 = lean_array_push(x_238, x_241); +x_243 = l_Lean_nullKind___closed__2; +x_244 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_244, 0, x_243); +lean_ctor_set(x_244, 1, x_242); +x_245 = l_myMacro____x40_Init_NotationExtra___hyg_5662____closed__4; +x_246 = lean_array_push(x_245, x_244); +x_247 = l_myMacro____x40_Init_Notation___hyg_1481____closed__8; +x_248 = lean_array_push(x_246, x_247); +x_249 = lean_array_push(x_248, x_247); +x_250 = lean_array_push(x_249, x_247); +x_251 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__7; +x_252 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_252, 0, x_251); +lean_ctor_set(x_252, 1, x_250); +x_253 = lean_array_push(x_238, x_252); +x_254 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__20; +lean_inc(x_166); +x_255 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_255, 0, x_166); +lean_ctor_set(x_255, 1, x_254); +x_256 = lean_array_push(x_238, x_255); +x_257 = lean_mk_syntax_ident(x_2); +x_258 = lean_array_push(x_238, x_257); +x_259 = lean_array_push(x_258, x_247); +x_260 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__23; +x_261 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_261, 0, x_260); +lean_ctor_set(x_261, 1, x_259); +x_262 = lean_array_push(x_256, x_261); +x_263 = l_Array_appendCore___rarg(x_238, x_14); +x_264 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_264, 0, x_243); +lean_ctor_set(x_264, 1, x_263); +x_265 = lean_array_push(x_238, x_264); +x_266 = l_myMacro____x40_Init_Notation___hyg_15378____closed__9; +lean_inc(x_166); +x_267 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_267, 0, x_166); +lean_ctor_set(x_267, 1, x_266); +x_268 = lean_array_push(x_238, x_267); +x_269 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__5; +x_270 = l_Lean_addMacroScope(x_234, x_269, x_169); +x_271 = l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__2; +x_272 = l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__4; +lean_inc(x_166); +x_273 = lean_alloc_ctor(3, 4, 0); +lean_ctor_set(x_273, 0, x_166); +lean_ctor_set(x_273, 1, x_271); +lean_ctor_set(x_273, 2, x_270); +lean_ctor_set(x_273, 3, x_272); +x_274 = lean_array_push(x_268, x_273); +x_275 = l_Lean_expandExplicitBindersAux_loop___closed__4; +x_276 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_276, 0, x_275); +lean_ctor_set(x_276, 1, x_274); +x_277 = lean_array_push(x_238, x_276); +x_278 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_278, 0, x_243); +lean_ctor_set(x_278, 1, x_277); +x_279 = lean_array_push(x_265, x_278); +x_280 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__25; +x_281 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_281, 0, x_280); +lean_ctor_set(x_281, 1, x_279); +x_282 = lean_array_push(x_262, x_281); +x_283 = l_myMacro____x40_Init_Notation___hyg_15947____closed__11; +x_284 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_284, 0, x_166); +lean_ctor_set(x_284, 1, x_283); +x_285 = lean_array_push(x_238, x_284); +x_286 = lean_array_push(x_285, x_5); +x_287 = lean_array_push(x_286, x_247); +x_288 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__33; +x_289 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_289, 0, x_288); +lean_ctor_set(x_289, 1, x_287); +x_290 = lean_array_push(x_282, x_289); +x_291 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__21; +x_292 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_292, 0, x_291); +lean_ctor_set(x_292, 1, x_290); +x_293 = lean_array_push(x_253, x_292); +x_294 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__5; +x_295 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_295, 0, x_294); +lean_ctor_set(x_295, 1, x_293); +x_296 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_296, 0, x_295); +lean_ctor_set(x_296, 1, x_235); +return x_296; +} +} +else +{ +lean_object* x_297; +x_297 = lean_box(0); +x_15 = x_297; +goto block_162; +} +} +else +{ +lean_object* x_298; +x_298 = lean_box(0); +x_15 = x_298; +goto block_162; +} +block_162: +{ +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; uint8_t x_23; +lean_dec(x_15); +x_16 = l_Lean_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInstImplicitBinders___spec__1___rarg(x_11, x_12, x_13); +x_17 = lean_ctor_get(x_16, 0); +lean_inc(x_17); +x_18 = lean_ctor_get(x_16, 1); +lean_inc(x_18); +lean_dec(x_16); +x_19 = l_Lean_Elab_Term_getCurrMacroScope(x_7, x_8, x_9, x_10, x_11, x_12, x_18); +x_20 = lean_ctor_get(x_19, 0); +lean_inc(x_20); +x_21 = lean_ctor_get(x_19, 1); +lean_inc(x_21); +lean_dec(x_19); +x_22 = l_Lean_Elab_Term_getMainModule___rarg(x_12, x_21); +x_23 = !lean_is_exclusive(x_22); +if (x_23 == 0) +{ +lean_object* x_24; lean_object* x_25; lean_object* x_26; lean_object* x_27; lean_object* x_28; lean_object* x_29; lean_object* x_30; lean_object* x_31; lean_object* x_32; lean_object* x_33; lean_object* x_34; lean_object* x_35; lean_object* x_36; lean_object* x_37; lean_object* x_38; lean_object* x_39; lean_object* x_40; lean_object* x_41; lean_object* x_42; lean_object* x_43; lean_object* x_44; lean_object* x_45; lean_object* x_46; lean_object* x_47; lean_object* x_48; lean_object* x_49; lean_object* x_50; lean_object* x_51; lean_object* x_52; lean_object* x_53; 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_65; lean_object* x_66; lean_object* x_67; lean_object* x_68; lean_object* x_69; lean_object* x_70; lean_object* x_71; lean_object* x_72; lean_object* x_73; lean_object* x_74; lean_object* x_75; lean_object* x_76; lean_object* x_77; lean_object* x_78; lean_object* x_79; lean_object* x_80; lean_object* x_81; lean_object* x_82; lean_object* x_83; lean_object* x_84; lean_object* x_85; lean_object* x_86; lean_object* x_87; lean_object* x_88; lean_object* x_89; lean_object* x_90; lean_object* x_91; +x_24 = lean_ctor_get(x_22, 0); +x_25 = l_Lean_Parser_Command_private___elambda__1___closed__1; +lean_inc(x_17); +x_26 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_26, 0, x_17); +lean_ctor_set(x_26, 1, x_25); +x_27 = l_Array_empty___closed__1; +x_28 = lean_array_push(x_27, x_26); +x_29 = l_Lean_Parser_Command_private___elambda__1___closed__2; +x_30 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_30, 0, x_29); +lean_ctor_set(x_30, 1, x_28); +x_31 = lean_array_push(x_27, x_30); +x_32 = l_Lean_nullKind___closed__2; +x_33 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_33, 0, x_32); +lean_ctor_set(x_33, 1, x_31); +x_34 = l_myMacro____x40_Init_NotationExtra___hyg_5662____closed__4; +x_35 = lean_array_push(x_34, x_33); +x_36 = l_myMacro____x40_Init_Notation___hyg_1481____closed__8; +x_37 = lean_array_push(x_35, x_36); +x_38 = lean_array_push(x_37, x_36); +x_39 = l_Lean_Parser_Command_partial___elambda__1___closed__1; +lean_inc(x_17); +x_40 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_40, 0, x_17); +lean_ctor_set(x_40, 1, x_39); +x_41 = lean_array_push(x_27, x_40); +x_42 = l_Lean_Parser_Command_partial___elambda__1___closed__2; +x_43 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_43, 0, x_42); +lean_ctor_set(x_43, 1, x_41); +x_44 = lean_array_push(x_27, x_43); +x_45 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_45, 0, x_32); +lean_ctor_set(x_45, 1, x_44); +x_46 = lean_array_push(x_38, x_45); +x_47 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__7; +x_48 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_48, 0, x_47); +lean_ctor_set(x_48, 1, x_46); +x_49 = lean_array_push(x_27, x_48); +x_50 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__20; +lean_inc(x_17); +x_51 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_51, 0, x_17); +lean_ctor_set(x_51, 1, x_50); +x_52 = lean_array_push(x_27, x_51); +x_53 = lean_mk_syntax_ident(x_2); +x_54 = lean_array_push(x_27, x_53); +x_55 = lean_array_push(x_54, x_36); +x_56 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__23; +x_57 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_57, 0, x_56); +lean_ctor_set(x_57, 1, x_55); +x_58 = lean_array_push(x_52, x_57); +x_59 = l_Array_appendCore___rarg(x_27, x_14); +x_60 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_60, 0, x_32); +lean_ctor_set(x_60, 1, x_59); +x_61 = lean_array_push(x_27, x_60); +x_62 = l_myMacro____x40_Init_Notation___hyg_15378____closed__9; +lean_inc(x_17); +x_63 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_63, 0, x_17); +lean_ctor_set(x_63, 1, x_62); +x_64 = lean_array_push(x_27, x_63); +x_65 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__5; +x_66 = l_Lean_addMacroScope(x_24, x_65, x_20); +x_67 = l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__2; +x_68 = l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__4; +lean_inc(x_17); +x_69 = lean_alloc_ctor(3, 4, 0); +lean_ctor_set(x_69, 0, x_17); +lean_ctor_set(x_69, 1, x_67); +lean_ctor_set(x_69, 2, x_66); +lean_ctor_set(x_69, 3, x_68); +x_70 = lean_array_push(x_64, x_69); +x_71 = l_Lean_expandExplicitBindersAux_loop___closed__4; +x_72 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_72, 0, x_71); +lean_ctor_set(x_72, 1, x_70); +x_73 = lean_array_push(x_27, x_72); +x_74 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_74, 0, x_32); +lean_ctor_set(x_74, 1, x_73); +x_75 = lean_array_push(x_61, x_74); +x_76 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__25; +x_77 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_77, 0, x_76); +lean_ctor_set(x_77, 1, x_75); +x_78 = lean_array_push(x_58, x_77); +x_79 = l_myMacro____x40_Init_Notation___hyg_15947____closed__11; +x_80 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_80, 0, x_17); +lean_ctor_set(x_80, 1, x_79); +x_81 = lean_array_push(x_27, x_80); +x_82 = lean_array_push(x_81, x_5); +x_83 = lean_array_push(x_82, x_36); +x_84 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__33; +x_85 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_85, 0, x_84); +lean_ctor_set(x_85, 1, x_83); +x_86 = lean_array_push(x_78, x_85); +x_87 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__21; +x_88 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_88, 0, x_87); +lean_ctor_set(x_88, 1, x_86); +x_89 = lean_array_push(x_49, x_88); +x_90 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__5; +x_91 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_91, 0, x_90); +lean_ctor_set(x_91, 1, x_89); +lean_ctor_set(x_22, 0, x_91); +return x_22; +} +else +{ +lean_object* x_92; lean_object* x_93; lean_object* x_94; lean_object* x_95; lean_object* x_96; lean_object* x_97; lean_object* x_98; lean_object* x_99; lean_object* x_100; lean_object* x_101; lean_object* x_102; lean_object* x_103; lean_object* x_104; lean_object* x_105; lean_object* x_106; lean_object* x_107; lean_object* x_108; 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; 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; 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; lean_object* x_134; lean_object* x_135; lean_object* x_136; lean_object* x_137; lean_object* x_138; lean_object* x_139; lean_object* x_140; lean_object* x_141; lean_object* x_142; lean_object* x_143; lean_object* x_144; lean_object* x_145; lean_object* x_146; lean_object* x_147; lean_object* x_148; lean_object* x_149; lean_object* x_150; lean_object* x_151; lean_object* x_152; lean_object* x_153; lean_object* x_154; lean_object* x_155; lean_object* x_156; lean_object* x_157; lean_object* x_158; lean_object* x_159; lean_object* x_160; lean_object* x_161; +x_92 = lean_ctor_get(x_22, 0); +x_93 = lean_ctor_get(x_22, 1); +lean_inc(x_93); +lean_inc(x_92); +lean_dec(x_22); +x_94 = l_Lean_Parser_Command_private___elambda__1___closed__1; +lean_inc(x_17); +x_95 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_95, 0, x_17); +lean_ctor_set(x_95, 1, x_94); +x_96 = l_Array_empty___closed__1; +x_97 = lean_array_push(x_96, x_95); +x_98 = l_Lean_Parser_Command_private___elambda__1___closed__2; +x_99 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_99, 0, x_98); +lean_ctor_set(x_99, 1, x_97); +x_100 = lean_array_push(x_96, x_99); +x_101 = l_Lean_nullKind___closed__2; +x_102 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_102, 0, x_101); +lean_ctor_set(x_102, 1, x_100); +x_103 = l_myMacro____x40_Init_NotationExtra___hyg_5662____closed__4; +x_104 = lean_array_push(x_103, x_102); +x_105 = l_myMacro____x40_Init_Notation___hyg_1481____closed__8; +x_106 = lean_array_push(x_104, x_105); +x_107 = lean_array_push(x_106, x_105); +x_108 = l_Lean_Parser_Command_partial___elambda__1___closed__1; +lean_inc(x_17); +x_109 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_109, 0, x_17); +lean_ctor_set(x_109, 1, x_108); +x_110 = lean_array_push(x_96, x_109); +x_111 = l_Lean_Parser_Command_partial___elambda__1___closed__2; +x_112 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_112, 0, x_111); +lean_ctor_set(x_112, 1, x_110); +x_113 = lean_array_push(x_96, x_112); +x_114 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_114, 0, x_101); +lean_ctor_set(x_114, 1, x_113); +x_115 = lean_array_push(x_107, x_114); +x_116 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__7; +x_117 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_117, 0, x_116); +lean_ctor_set(x_117, 1, x_115); +x_118 = lean_array_push(x_96, x_117); +x_119 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__20; +lean_inc(x_17); +x_120 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_120, 0, x_17); +lean_ctor_set(x_120, 1, x_119); +x_121 = lean_array_push(x_96, x_120); +x_122 = lean_mk_syntax_ident(x_2); +x_123 = lean_array_push(x_96, x_122); +x_124 = lean_array_push(x_123, x_105); +x_125 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__23; +x_126 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_126, 0, x_125); +lean_ctor_set(x_126, 1, x_124); +x_127 = lean_array_push(x_121, x_126); +x_128 = l_Array_appendCore___rarg(x_96, x_14); +x_129 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_129, 0, x_101); +lean_ctor_set(x_129, 1, x_128); +x_130 = lean_array_push(x_96, x_129); +x_131 = l_myMacro____x40_Init_Notation___hyg_15378____closed__9; +lean_inc(x_17); +x_132 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_132, 0, x_17); +lean_ctor_set(x_132, 1, x_131); +x_133 = lean_array_push(x_96, x_132); +x_134 = l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__5; +x_135 = l_Lean_addMacroScope(x_92, x_134, x_20); +x_136 = l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__2; +x_137 = l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__4; +lean_inc(x_17); +x_138 = lean_alloc_ctor(3, 4, 0); +lean_ctor_set(x_138, 0, x_17); +lean_ctor_set(x_138, 1, x_136); +lean_ctor_set(x_138, 2, x_135); +lean_ctor_set(x_138, 3, x_137); +x_139 = lean_array_push(x_133, x_138); +x_140 = l_Lean_expandExplicitBindersAux_loop___closed__4; +x_141 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_141, 0, x_140); +lean_ctor_set(x_141, 1, x_139); +x_142 = lean_array_push(x_96, x_141); +x_143 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_143, 0, x_101); +lean_ctor_set(x_143, 1, x_142); +x_144 = lean_array_push(x_130, x_143); +x_145 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__25; +x_146 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_146, 0, x_145); +lean_ctor_set(x_146, 1, x_144); +x_147 = lean_array_push(x_127, x_146); +x_148 = l_myMacro____x40_Init_Notation___hyg_15947____closed__11; +x_149 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_149, 0, x_17); +lean_ctor_set(x_149, 1, x_148); +x_150 = lean_array_push(x_96, x_149); +x_151 = lean_array_push(x_150, x_5); +x_152 = lean_array_push(x_151, x_105); +x_153 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__33; +x_154 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_154, 0, x_153); +lean_ctor_set(x_154, 1, x_152); +x_155 = lean_array_push(x_147, x_154); +x_156 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__21; +x_157 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_157, 0, x_156); +lean_ctor_set(x_157, 1, x_155); +x_158 = lean_array_push(x_118, x_157); +x_159 = l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__5; +x_160 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_160, 0, x_159); +lean_ctor_set(x_160, 1, x_158); +x_161 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_161, 0, x_160); +lean_ctor_set(x_161, 1, x_93); +return x_161; +} +} +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkAuxFunction(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6, lean_object* x_7, lean_object* x_8, lean_object* x_9) { +_start: +{ +lean_object* x_10; lean_object* x_11; lean_object* x_12; lean_object* x_13; lean_object* x_14; lean_object* x_15; lean_object* x_16; +x_10 = lean_ctor_get(x_1, 1); +x_11 = l_Lean_instInhabitedName; +x_12 = lean_array_get(x_11, x_10, x_2); +x_13 = lean_ctor_get(x_1, 0); +x_14 = l_Lean_instInhabitedInductiveVal; +x_15 = lean_array_get(x_14, x_13, x_2); +lean_inc(x_8); +lean_inc(x_7); +lean_inc(x_6); +lean_inc(x_5); +lean_inc(x_4); +lean_inc(x_3); +lean_inc(x_15); +x_16 = l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg(x_15, x_3, x_4, x_5, x_6, x_7, x_8, x_9); +if (lean_obj_tag(x_16) == 0) +{ +lean_object* x_17; lean_object* x_18; lean_object* x_19; +x_17 = lean_ctor_get(x_16, 0); +lean_inc(x_17); +x_18 = lean_ctor_get(x_16, 1); +lean_inc(x_18); +lean_dec(x_16); +lean_inc(x_8); +lean_inc(x_7); +lean_inc(x_6); +lean_inc(x_5); +lean_inc(x_4); +lean_inc(x_3); +lean_inc(x_15); +lean_inc(x_17); +x_19 = l_Lean_Elab_Deriving_Ord_mkMatch___rarg(x_17, x_15, x_12, x_3, x_4, x_5, x_6, x_7, x_8, x_18); +if (lean_obj_tag(x_19) == 0) +{ +uint8_t x_20; +x_20 = lean_ctor_get_uint8(x_1, sizeof(void*)*2); +if (x_20 == 0) +{ +uint8_t x_21; +x_21 = lean_ctor_get_uint8(x_15, sizeof(void*)*5); +if (x_21 == 0) +{ +lean_object* x_22; lean_object* x_23; lean_object* x_24; lean_object* x_25; +x_22 = lean_ctor_get(x_19, 0); +lean_inc(x_22); +x_23 = lean_ctor_get(x_19, 1); +lean_inc(x_23); +lean_dec(x_19); +x_24 = lean_box(0); +x_25 = l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1(x_17, x_12, x_1, x_15, x_22, x_24, x_3, x_4, x_5, x_6, x_7, x_8, x_23); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_15); +lean_dec(x_17); +return x_25; +} +else +{ +lean_object* x_26; lean_object* x_27; lean_object* x_28; lean_object* x_29; lean_object* x_30; +x_26 = lean_ctor_get(x_19, 0); +lean_inc(x_26); +x_27 = lean_ctor_get(x_19, 1); +lean_inc(x_27); +lean_dec(x_19); +x_28 = lean_ctor_get(x_17, 1); +lean_inc(x_28); +x_29 = l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg___closed__2; +lean_inc(x_8); +lean_inc(x_7); +lean_inc(x_6); +lean_inc(x_5); +lean_inc(x_4); +lean_inc(x_3); +x_30 = l_Lean_Elab_Deriving_mkLocalInstanceLetDecls(x_1, x_29, x_28, x_3, x_4, x_5, x_6, x_7, x_8, x_27); +if (lean_obj_tag(x_30) == 0) +{ +lean_object* x_31; lean_object* x_32; lean_object* x_33; lean_object* x_34; lean_object* x_35; lean_object* x_36; lean_object* x_37; +x_31 = lean_ctor_get(x_30, 0); +lean_inc(x_31); +x_32 = lean_ctor_get(x_30, 1); +lean_inc(x_32); +lean_dec(x_30); +x_33 = l_Lean_Elab_Deriving_mkLet(x_31, x_26, x_3, x_4, x_5, x_6, x_7, x_8, x_32); +lean_dec(x_31); +x_34 = lean_ctor_get(x_33, 0); +lean_inc(x_34); +x_35 = lean_ctor_get(x_33, 1); +lean_inc(x_35); +lean_dec(x_33); +x_36 = lean_box(0); +x_37 = l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1(x_17, x_12, x_1, x_15, x_34, x_36, x_3, x_4, x_5, x_6, x_7, x_8, x_35); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_15); +lean_dec(x_17); +return x_37; +} +else +{ +uint8_t x_38; +lean_dec(x_26); +lean_dec(x_17); +lean_dec(x_15); +lean_dec(x_12); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_3); +x_38 = !lean_is_exclusive(x_30); +if (x_38 == 0) +{ +return x_30; +} +else +{ +lean_object* x_39; lean_object* x_40; lean_object* x_41; +x_39 = lean_ctor_get(x_30, 0); +x_40 = lean_ctor_get(x_30, 1); +lean_inc(x_40); +lean_inc(x_39); +lean_dec(x_30); +x_41 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_41, 0, x_39); +lean_ctor_set(x_41, 1, x_40); +return x_41; +} +} +} +} +else +{ +lean_object* x_42; lean_object* x_43; lean_object* x_44; lean_object* x_45; lean_object* x_46; +x_42 = lean_ctor_get(x_19, 0); +lean_inc(x_42); +x_43 = lean_ctor_get(x_19, 1); +lean_inc(x_43); +lean_dec(x_19); +x_44 = lean_ctor_get(x_17, 1); +lean_inc(x_44); +x_45 = l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg___closed__2; +lean_inc(x_8); +lean_inc(x_7); +lean_inc(x_6); +lean_inc(x_5); +lean_inc(x_4); +lean_inc(x_3); +x_46 = l_Lean_Elab_Deriving_mkLocalInstanceLetDecls(x_1, x_45, x_44, x_3, x_4, x_5, x_6, x_7, x_8, x_43); +if (lean_obj_tag(x_46) == 0) +{ +lean_object* x_47; lean_object* x_48; lean_object* x_49; lean_object* x_50; lean_object* x_51; lean_object* x_52; lean_object* x_53; +x_47 = lean_ctor_get(x_46, 0); +lean_inc(x_47); +x_48 = lean_ctor_get(x_46, 1); +lean_inc(x_48); +lean_dec(x_46); +x_49 = l_Lean_Elab_Deriving_mkLet(x_47, x_42, x_3, x_4, x_5, x_6, x_7, x_8, x_48); +lean_dec(x_47); +x_50 = lean_ctor_get(x_49, 0); +lean_inc(x_50); +x_51 = lean_ctor_get(x_49, 1); +lean_inc(x_51); +lean_dec(x_49); +x_52 = lean_box(0); +x_53 = l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1(x_17, x_12, x_1, x_15, x_50, x_52, x_3, x_4, x_5, x_6, x_7, x_8, x_51); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_15); +lean_dec(x_17); +return x_53; +} +else +{ +uint8_t x_54; +lean_dec(x_42); +lean_dec(x_17); +lean_dec(x_15); +lean_dec(x_12); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_3); +x_54 = !lean_is_exclusive(x_46); +if (x_54 == 0) +{ +return x_46; +} +else +{ +lean_object* x_55; lean_object* x_56; lean_object* x_57; +x_55 = lean_ctor_get(x_46, 0); +x_56 = lean_ctor_get(x_46, 1); +lean_inc(x_56); +lean_inc(x_55); +lean_dec(x_46); +x_57 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_57, 0, x_55); +lean_ctor_set(x_57, 1, x_56); +return x_57; +} +} +} +} +else +{ +uint8_t x_58; +lean_dec(x_17); +lean_dec(x_15); +lean_dec(x_12); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_3); +x_58 = !lean_is_exclusive(x_19); +if (x_58 == 0) +{ +return x_19; +} +else +{ +lean_object* x_59; lean_object* x_60; lean_object* x_61; +x_59 = lean_ctor_get(x_19, 0); +x_60 = lean_ctor_get(x_19, 1); +lean_inc(x_60); +lean_inc(x_59); +lean_dec(x_19); +x_61 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_61, 0, x_59); +lean_ctor_set(x_61, 1, x_60); +return x_61; +} +} +} +else +{ +uint8_t x_62; +lean_dec(x_15); +lean_dec(x_12); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_3); +x_62 = !lean_is_exclusive(x_16); +if (x_62 == 0) +{ +return x_16; +} +else +{ +lean_object* x_63; lean_object* x_64; lean_object* x_65; +x_63 = lean_ctor_get(x_16, 0); +x_64 = lean_ctor_get(x_16, 1); +lean_inc(x_64); +lean_inc(x_63); +lean_dec(x_16); +x_65 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_65, 0, x_63); +lean_ctor_set(x_65, 1, x_64); +return x_65; +} +} +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkAuxFunction___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_object* x_8, lean_object* x_9, lean_object* x_10, lean_object* x_11, lean_object* x_12, lean_object* x_13) { +_start: +{ +lean_object* x_14; +x_14 = l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9, x_10, x_11, x_12, x_13); +lean_dec(x_12); +lean_dec(x_11); +lean_dec(x_10); +lean_dec(x_9); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_1); +return x_14; +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkAuxFunction___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, lean_object* x_9) { +_start: +{ +lean_object* x_10; +x_10 = l_Lean_Elab_Deriving_Ord_mkAuxFunction(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9); +lean_dec(x_2); +lean_dec(x_1); +return x_10; +} +} +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMutualBlock___spec__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_object* x_8, lean_object* x_9, lean_object* x_10, lean_object* x_11, lean_object* x_12) { +_start: +{ +lean_object* x_13; uint8_t x_14; +x_13 = lean_ctor_get(x_2, 1); +x_14 = lean_nat_dec_le(x_13, x_4); +if (x_14 == 0) +{ +lean_object* x_15; uint8_t x_16; +x_15 = lean_unsigned_to_nat(0u); +x_16 = lean_nat_dec_eq(x_3, x_15); +if (x_16 == 0) +{ +lean_object* x_17; lean_object* x_18; lean_object* x_19; +x_17 = lean_unsigned_to_nat(1u); +x_18 = lean_nat_sub(x_3, x_17); +lean_dec(x_3); +lean_inc(x_11); +lean_inc(x_10); +lean_inc(x_9); +lean_inc(x_8); +lean_inc(x_7); +lean_inc(x_6); +x_19 = l_Lean_Elab_Deriving_Ord_mkAuxFunction(x_1, x_4, x_6, x_7, x_8, x_9, x_10, x_11, x_12); +if (lean_obj_tag(x_19) == 0) +{ +lean_object* x_20; lean_object* x_21; lean_object* x_22; lean_object* x_23; lean_object* x_24; +x_20 = lean_ctor_get(x_19, 0); +lean_inc(x_20); +x_21 = lean_ctor_get(x_19, 1); +lean_inc(x_21); +lean_dec(x_19); +x_22 = lean_array_push(x_5, x_20); +x_23 = lean_ctor_get(x_2, 2); +x_24 = lean_nat_add(x_4, x_23); +lean_dec(x_4); +x_3 = x_18; +x_4 = x_24; +x_5 = x_22; +x_12 = x_21; +goto _start; +} +else +{ +uint8_t x_26; +lean_dec(x_18); +lean_dec(x_11); +lean_dec(x_10); +lean_dec(x_9); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +x_26 = !lean_is_exclusive(x_19); +if (x_26 == 0) +{ +return x_19; +} +else +{ +lean_object* x_27; lean_object* x_28; lean_object* x_29; +x_27 = lean_ctor_get(x_19, 0); +x_28 = lean_ctor_get(x_19, 1); +lean_inc(x_28); +lean_inc(x_27); +lean_dec(x_19); +x_29 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_29, 0, x_27); +lean_ctor_set(x_29, 1, x_28); +return x_29; +} +} +} +else +{ +lean_object* x_30; +lean_dec(x_11); +lean_dec(x_10); +lean_dec(x_9); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_4); +lean_dec(x_3); +x_30 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_30, 0, x_5); +lean_ctor_set(x_30, 1, x_12); +return x_30; +} +} +else +{ +lean_object* x_31; +lean_dec(x_11); +lean_dec(x_10); +lean_dec(x_9); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_4); +lean_dec(x_3); +x_31 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_31, 0, x_5); +lean_ctor_set(x_31, 1, x_12); +return x_31; +} +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkMutualBlock(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_object* x_10; lean_object* x_11; lean_object* x_12; lean_object* x_13; lean_object* x_14; lean_object* x_15; +x_9 = lean_ctor_get(x_1, 0); +x_10 = lean_array_get_size(x_9); +x_11 = lean_unsigned_to_nat(0u); +x_12 = lean_unsigned_to_nat(1u); +lean_inc(x_10); +x_13 = lean_alloc_ctor(0, 3, 0); +lean_ctor_set(x_13, 0, x_11); +lean_ctor_set(x_13, 1, x_10); +lean_ctor_set(x_13, 2, x_12); +x_14 = l_Array_empty___closed__1; +lean_inc(x_7); +lean_inc(x_6); +lean_inc(x_5); +lean_inc(x_4); +lean_inc(x_3); +lean_inc(x_2); +x_15 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMutualBlock___spec__1(x_1, x_13, x_10, x_11, x_14, x_2, x_3, x_4, x_5, x_6, x_7, x_8); +lean_dec(x_13); +if (lean_obj_tag(x_15) == 0) +{ +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; uint8_t x_24; +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_MonadRef_mkInfoFromRefPos___at_Lean_Elab_Deriving_mkInductiveApp___spec__2___rarg(x_6, x_7, x_17); +x_19 = lean_ctor_get(x_18, 0); +lean_inc(x_19); +x_20 = lean_ctor_get(x_18, 1); +lean_inc(x_20); +lean_dec(x_18); +x_21 = l_Lean_Elab_Term_getCurrMacroScope(x_2, x_3, x_4, x_5, x_6, x_7, x_20); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_2); +x_22 = lean_ctor_get(x_21, 1); +lean_inc(x_22); +lean_dec(x_21); +x_23 = l_Lean_Elab_Term_getMainModule___rarg(x_7, x_22); +lean_dec(x_7); +x_24 = !lean_is_exclusive(x_23); +if (x_24 == 0) +{ +lean_object* x_25; lean_object* x_26; lean_object* x_27; lean_object* x_28; lean_object* x_29; lean_object* x_30; lean_object* x_31; lean_object* x_32; lean_object* x_33; lean_object* x_34; lean_object* x_35; lean_object* x_36; lean_object* x_37; +x_25 = lean_ctor_get(x_23, 0); +lean_dec(x_25); +x_26 = l_Lean_Parser_Command_mutual___elambda__1___closed__1; +lean_inc(x_19); +x_27 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_27, 0, x_19); +lean_ctor_set(x_27, 1, x_26); +x_28 = lean_array_push(x_14, x_27); +x_29 = l_Array_appendCore___rarg(x_14, x_16); +lean_dec(x_16); +x_30 = l_Lean_nullKind___closed__2; +x_31 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_31, 0, x_30); +lean_ctor_set(x_31, 1, x_29); +x_32 = lean_array_push(x_28, x_31); +x_33 = l_Lean_Parser_Command_end___elambda__1___closed__1; +x_34 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_34, 0, x_19); +lean_ctor_set(x_34, 1, x_33); +x_35 = lean_array_push(x_32, x_34); +x_36 = l_Lean_Parser_Command_mutual___elambda__1___closed__2; +x_37 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_37, 0, x_36); +lean_ctor_set(x_37, 1, x_35); +lean_ctor_set(x_23, 0, x_37); +return x_23; +} +else +{ +lean_object* x_38; lean_object* x_39; lean_object* x_40; lean_object* x_41; lean_object* x_42; lean_object* x_43; lean_object* x_44; lean_object* x_45; lean_object* x_46; lean_object* x_47; lean_object* x_48; lean_object* x_49; lean_object* x_50; lean_object* x_51; +x_38 = lean_ctor_get(x_23, 1); +lean_inc(x_38); +lean_dec(x_23); +x_39 = l_Lean_Parser_Command_mutual___elambda__1___closed__1; +lean_inc(x_19); +x_40 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_40, 0, x_19); +lean_ctor_set(x_40, 1, x_39); +x_41 = lean_array_push(x_14, x_40); +x_42 = l_Array_appendCore___rarg(x_14, x_16); +lean_dec(x_16); +x_43 = l_Lean_nullKind___closed__2; +x_44 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_44, 0, x_43); +lean_ctor_set(x_44, 1, x_42); +x_45 = lean_array_push(x_41, x_44); +x_46 = l_Lean_Parser_Command_end___elambda__1___closed__1; +x_47 = lean_alloc_ctor(2, 2, 0); +lean_ctor_set(x_47, 0, x_19); +lean_ctor_set(x_47, 1, x_46); +x_48 = lean_array_push(x_45, x_47); +x_49 = l_Lean_Parser_Command_mutual___elambda__1___closed__2; +x_50 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_50, 0, x_49); +lean_ctor_set(x_50, 1, x_48); +x_51 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_51, 0, x_50); +lean_ctor_set(x_51, 1, x_38); +return x_51; +} +} +else +{ +uint8_t x_52; +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_2); +x_52 = !lean_is_exclusive(x_15); +if (x_52 == 0) +{ +return x_15; +} +else +{ +lean_object* x_53; lean_object* x_54; lean_object* x_55; +x_53 = lean_ctor_get(x_15, 0); +x_54 = lean_ctor_get(x_15, 1); +lean_inc(x_54); +lean_inc(x_53); +lean_dec(x_15); +x_55 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_55, 0, x_53); +lean_ctor_set(x_55, 1, x_54); +return x_55; +} +} +} +} +lean_object* l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMutualBlock___spec__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_object* x_8, lean_object* x_9, lean_object* x_10, lean_object* x_11, lean_object* x_12) { +_start: +{ +lean_object* x_13; +x_13 = l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMutualBlock___spec__1(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9, x_10, x_11, x_12); +lean_dec(x_2); +lean_dec(x_1); +return x_13; +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkMutualBlock___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_Deriving_Ord_mkMutualBlock(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8); +lean_dec(x_1); +return x_9; +} +} +lean_object* l_List_map___at___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___spec__1(lean_object* x_1) { +_start: +{ +if (lean_obj_tag(x_1) == 0) +{ +lean_object* x_2; +x_2 = lean_box(0); +return x_2; +} +else +{ +uint8_t x_3; +x_3 = !lean_is_exclusive(x_1); +if (x_3 == 0) +{ +lean_object* x_4; lean_object* x_5; lean_object* x_6; lean_object* x_7; +x_4 = lean_ctor_get(x_1, 0); +x_5 = lean_ctor_get(x_1, 1); +x_6 = lean_alloc_ctor(1, 1, 0); +lean_ctor_set(x_6, 0, x_4); +x_7 = l_List_map___at___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___spec__1(x_5); +lean_ctor_set(x_1, 1, x_7); +lean_ctor_set(x_1, 0, x_6); +return x_1; +} +else +{ +lean_object* x_8; lean_object* x_9; lean_object* x_10; lean_object* x_11; lean_object* x_12; +x_8 = lean_ctor_get(x_1, 0); +x_9 = lean_ctor_get(x_1, 1); +lean_inc(x_9); +lean_inc(x_8); +lean_dec(x_1); +x_10 = lean_alloc_ctor(1, 1, 0); +lean_ctor_set(x_10, 0, x_8); +x_11 = l_List_map___at___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___spec__1(x_9); +x_12 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_12, 0, x_10); +lean_ctor_set(x_12, 1, x_11); +return x_12; +} +} +} +} +static lean_object* _init_l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___closed__1() { +_start: +{ +lean_object* x_1; +x_1 = lean_mk_string("ord"); +return x_1; +} +} +static lean_object* _init_l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___closed__2() { +_start: +{ +lean_object* x_1; lean_object* x_2; lean_object* x_3; +x_1 = l_Lean_Elab_Deriving_mkContext___closed__2; +x_2 = l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___closed__1; +x_3 = lean_name_mk_string(x_1, x_2); +return x_3; +} +} +lean_object* l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds(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_object* x_10; lean_object* x_11; lean_object* x_12; lean_object* x_13; +x_9 = l_Lean_instInhabitedName; +x_10 = lean_unsigned_to_nat(0u); +x_11 = lean_array_get(x_9, x_1, x_10); +x_12 = l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___closed__1; +lean_inc(x_2); +x_13 = l_Lean_Elab_Deriving_mkContext(x_12, x_11, x_2, x_3, x_4, x_5, x_6, x_7, x_8); +if (lean_obj_tag(x_13) == 0) +{ +lean_object* x_14; lean_object* x_15; lean_object* x_16; +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); +lean_inc(x_7); +lean_inc(x_6); +lean_inc(x_5); +lean_inc(x_4); +lean_inc(x_3); +lean_inc(x_2); +x_16 = l_Lean_Elab_Deriving_Ord_mkMutualBlock(x_14, x_2, x_3, x_4, x_5, x_6, x_7, x_15); +if (lean_obj_tag(x_16) == 0) +{ +lean_object* x_17; lean_object* x_18; lean_object* x_19; uint8_t x_20; lean_object* x_21; +x_17 = lean_ctor_get(x_16, 0); +lean_inc(x_17); +x_18 = lean_ctor_get(x_16, 1); +lean_inc(x_18); +lean_dec(x_16); +x_19 = l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg___closed__2; +x_20 = 1; +lean_inc(x_7); +lean_inc(x_6); +lean_inc(x_5); +lean_inc(x_4); +lean_inc(x_3); +lean_inc(x_2); +x_21 = l_Lean_Elab_Deriving_mkInstanceCmds(x_14, x_19, x_1, x_20, x_2, x_3, x_4, x_5, x_6, x_7, x_18); +lean_dec(x_14); +if (lean_obj_tag(x_21) == 0) +{ +lean_object* x_22; lean_object* x_23; lean_object* x_24; lean_object* x_25; lean_object* x_26; lean_object* x_27; uint8_t x_28; lean_object* x_29; lean_object* x_45; lean_object* x_46; lean_object* x_47; uint8_t x_48; +x_22 = lean_ctor_get(x_21, 0); +lean_inc(x_22); +x_23 = lean_ctor_get(x_21, 1); +lean_inc(x_23); +if (lean_is_exclusive(x_21)) { + lean_ctor_release(x_21, 0); + lean_ctor_release(x_21, 1); + x_24 = x_21; +} else { + lean_dec_ref(x_21); + x_24 = lean_box(0); +} +x_25 = l_Lean_mkOptionalNode___closed__2; +x_26 = lean_array_push(x_25, x_17); +x_27 = l_Array_append___rarg(x_26, x_22); +lean_dec(x_22); +x_45 = lean_st_ref_get(x_7, x_23); +x_46 = lean_ctor_get(x_45, 0); +lean_inc(x_46); +x_47 = lean_ctor_get(x_46, 3); +lean_inc(x_47); +lean_dec(x_46); +x_48 = lean_ctor_get_uint8(x_47, sizeof(void*)*1); +lean_dec(x_47); +if (x_48 == 0) +{ +lean_object* x_49; uint8_t x_50; +x_49 = lean_ctor_get(x_45, 1); +lean_inc(x_49); +lean_dec(x_45); +x_50 = 0; +x_28 = x_50; +x_29 = x_49; +goto block_44; +} +else +{ +lean_object* x_51; lean_object* x_52; lean_object* x_53; lean_object* x_54; lean_object* x_55; uint8_t x_56; +x_51 = lean_ctor_get(x_45, 1); +lean_inc(x_51); +lean_dec(x_45); +x_52 = l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___closed__2; +x_53 = l___private_Lean_Util_Trace_0__Lean_checkTraceOptionM___at___private_Lean_Elab_Term_0__Lean_Elab_Term_postponeElabTerm___spec__2(x_52, x_2, x_3, x_4, x_5, x_6, x_7, x_51); +x_54 = lean_ctor_get(x_53, 0); +lean_inc(x_54); +x_55 = lean_ctor_get(x_53, 1); +lean_inc(x_55); +lean_dec(x_53); +x_56 = lean_unbox(x_54); +lean_dec(x_54); +x_28 = x_56; +x_29 = x_55; +goto block_44; +} +block_44: +{ +if (x_28 == 0) +{ +lean_object* x_30; +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_2); +if (lean_is_scalar(x_24)) { + x_30 = lean_alloc_ctor(0, 2, 0); +} else { + x_30 = x_24; +} +lean_ctor_set(x_30, 0, x_27); +lean_ctor_set(x_30, 1, x_29); +return x_30; +} +else +{ +lean_object* x_31; lean_object* x_32; lean_object* x_33; lean_object* x_34; lean_object* x_35; lean_object* x_36; lean_object* x_37; lean_object* x_38; lean_object* x_39; uint8_t x_40; +lean_dec(x_24); +lean_inc(x_27); +x_31 = lean_array_to_list(lean_box(0), x_27); +x_32 = l_List_map___at___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___spec__1(x_31); +x_33 = l_Lean_MessageData_ofList(x_32); +lean_dec(x_32); +x_34 = l_Array_foldlMUnsafe_fold___at___private_Lean_Util_Trace_0__Lean_withNestedTracesFinalizer___spec__5___closed__1; +x_35 = lean_alloc_ctor(10, 2, 0); +lean_ctor_set(x_35, 0, x_34); +lean_ctor_set(x_35, 1, x_33); +x_36 = l_Lean_KernelException_toMessageData___closed__15; +x_37 = lean_alloc_ctor(10, 2, 0); +lean_ctor_set(x_37, 0, x_35); +lean_ctor_set(x_37, 1, x_36); +x_38 = l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___closed__2; +x_39 = l_Lean_addTrace___at___private_Lean_Elab_Term_0__Lean_Elab_Term_postponeElabTerm___spec__1(x_38, x_37, x_2, x_3, x_4, x_5, x_6, x_7, x_29); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_2); +x_40 = !lean_is_exclusive(x_39); +if (x_40 == 0) +{ +lean_object* x_41; +x_41 = lean_ctor_get(x_39, 0); +lean_dec(x_41); +lean_ctor_set(x_39, 0, x_27); +return x_39; +} +else +{ +lean_object* x_42; lean_object* x_43; +x_42 = lean_ctor_get(x_39, 1); +lean_inc(x_42); +lean_dec(x_39); +x_43 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_43, 0, x_27); +lean_ctor_set(x_43, 1, x_42); +return x_43; +} +} +} +} +else +{ +uint8_t x_57; +lean_dec(x_17); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_2); +x_57 = !lean_is_exclusive(x_21); +if (x_57 == 0) +{ +return x_21; +} +else +{ +lean_object* x_58; lean_object* x_59; lean_object* x_60; +x_58 = lean_ctor_get(x_21, 0); +x_59 = lean_ctor_get(x_21, 1); +lean_inc(x_59); +lean_inc(x_58); +lean_dec(x_21); +x_60 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_60, 0, x_58); +lean_ctor_set(x_60, 1, x_59); +return x_60; +} +} +} +else +{ +uint8_t x_61; +lean_dec(x_14); +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_2); +x_61 = !lean_is_exclusive(x_16); +if (x_61 == 0) +{ +return x_16; +} +else +{ +lean_object* x_62; lean_object* x_63; lean_object* x_64; +x_62 = lean_ctor_get(x_16, 0); +x_63 = lean_ctor_get(x_16, 1); +lean_inc(x_63); +lean_inc(x_62); +lean_dec(x_16); +x_64 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_64, 0, x_62); +lean_ctor_set(x_64, 1, x_63); +return x_64; +} +} +} +else +{ +uint8_t x_65; +lean_dec(x_7); +lean_dec(x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_2); +x_65 = !lean_is_exclusive(x_13); +if (x_65 == 0) +{ +return x_13; +} +else +{ +lean_object* x_66; lean_object* x_67; lean_object* x_68; +x_66 = lean_ctor_get(x_13, 0); +x_67 = lean_ctor_get(x_13, 1); +lean_inc(x_67); +lean_inc(x_66); +lean_dec(x_13); +x_68 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_68, 0, x_66); +lean_ctor_set(x_68, 1, x_67); +return x_68; +} +} +} +} +lean_object* l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___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___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8); +lean_dec(x_1); +return x_9; +} +} +lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___spec__1(lean_object* x_1, size_t x_2, size_t x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6, lean_object* x_7) { +_start: +{ +uint8_t x_8; +x_8 = x_2 == x_3; +if (x_8 == 0) +{ +lean_object* x_9; lean_object* x_10; +lean_dec(x_4); +x_9 = lean_array_uget(x_1, x_2); +lean_inc(x_6); +x_10 = l_Lean_Elab_Command_elabCommand(x_9, x_5, x_6, x_7); +if (lean_obj_tag(x_10) == 0) +{ +lean_object* x_11; lean_object* x_12; size_t x_13; size_t x_14; +x_11 = lean_ctor_get(x_10, 0); +lean_inc(x_11); +x_12 = lean_ctor_get(x_10, 1); +lean_inc(x_12); +lean_dec(x_10); +x_13 = 1; +x_14 = x_2 + x_13; +x_2 = x_14; +x_4 = x_11; +x_7 = x_12; +goto _start; +} +else +{ +uint8_t x_16; +lean_dec(x_6); +x_16 = !lean_is_exclusive(x_10); +if (x_16 == 0) +{ +return x_10; +} +else +{ +lean_object* x_17; lean_object* x_18; lean_object* x_19; +x_17 = lean_ctor_get(x_10, 0); +x_18 = lean_ctor_get(x_10, 1); +lean_inc(x_18); +lean_inc(x_17); +lean_dec(x_10); +x_19 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_19, 0, x_17); +lean_ctor_set(x_19, 1, x_18); +return x_19; +} +} +} +else +{ +lean_object* x_20; +lean_dec(x_6); +x_20 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_20, 0, x_4); +lean_ctor_set(x_20, 1, x_7); +return x_20; +} +} +} +lean_object* l_Lean_isInductive___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___spec__2(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4) { +_start: +{ +lean_object* x_5; uint8_t x_6; +x_5 = lean_st_ref_get(x_3, x_4); +x_6 = !lean_is_exclusive(x_5); +if (x_6 == 0) +{ +lean_object* x_7; lean_object* x_8; lean_object* x_9; +x_7 = lean_ctor_get(x_5, 0); +x_8 = lean_ctor_get(x_7, 0); +lean_inc(x_8); +lean_dec(x_7); +x_9 = lean_environment_find(x_8, x_1); +if (lean_obj_tag(x_9) == 0) +{ +uint8_t x_10; lean_object* x_11; +x_10 = 0; +x_11 = lean_box(x_10); +lean_ctor_set(x_5, 0, x_11); +return x_5; +} +else +{ +lean_object* x_12; +x_12 = lean_ctor_get(x_9, 0); +lean_inc(x_12); +lean_dec(x_9); +if (lean_obj_tag(x_12) == 5) +{ +uint8_t x_13; lean_object* x_14; +lean_dec(x_12); +x_13 = 1; +x_14 = lean_box(x_13); +lean_ctor_set(x_5, 0, x_14); +return x_5; +} +else +{ +uint8_t x_15; lean_object* x_16; +lean_dec(x_12); +x_15 = 0; +x_16 = lean_box(x_15); +lean_ctor_set(x_5, 0, x_16); +return x_5; +} +} +} +else +{ +lean_object* x_17; lean_object* x_18; lean_object* x_19; lean_object* x_20; +x_17 = lean_ctor_get(x_5, 0); +x_18 = lean_ctor_get(x_5, 1); +lean_inc(x_18); +lean_inc(x_17); +lean_dec(x_5); +x_19 = lean_ctor_get(x_17, 0); +lean_inc(x_19); +lean_dec(x_17); +x_20 = lean_environment_find(x_19, x_1); +if (lean_obj_tag(x_20) == 0) +{ +uint8_t x_21; lean_object* x_22; lean_object* x_23; +x_21 = 0; +x_22 = lean_box(x_21); +x_23 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_23, 0, x_22); +lean_ctor_set(x_23, 1, x_18); +return x_23; +} +else +{ +lean_object* x_24; +x_24 = lean_ctor_get(x_20, 0); +lean_inc(x_24); +lean_dec(x_20); +if (lean_obj_tag(x_24) == 5) +{ +uint8_t x_25; lean_object* x_26; lean_object* x_27; +lean_dec(x_24); +x_25 = 1; +x_26 = lean_box(x_25); +x_27 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_27, 0, x_26); +lean_ctor_set(x_27, 1, x_18); +return x_27; +} +else +{ +uint8_t x_28; lean_object* x_29; lean_object* x_30; +lean_dec(x_24); +x_28 = 0; +x_29 = lean_box(x_28); +x_30 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_30, 0, x_29); +lean_ctor_set(x_30, 1, x_18); +return x_30; +} +} +} +} +} +lean_object* l_Array_anyMUnsafe_any___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___spec__3(lean_object* x_1, size_t x_2, size_t x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6) { +_start: +{ +uint8_t x_7; +x_7 = x_2 == x_3; +if (x_7 == 0) +{ +lean_object* x_8; lean_object* x_9; lean_object* x_10; uint8_t x_11; +x_8 = lean_array_uget(x_1, x_2); +x_9 = l_Lean_isInductive___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___spec__2(x_8, x_4, x_5, x_6); +x_10 = lean_ctor_get(x_9, 0); +lean_inc(x_10); +x_11 = lean_unbox(x_10); +lean_dec(x_10); +if (x_11 == 0) +{ +uint8_t x_12; +x_12 = !lean_is_exclusive(x_9); +if (x_12 == 0) +{ +lean_object* x_13; uint8_t x_14; lean_object* x_15; +x_13 = lean_ctor_get(x_9, 0); +lean_dec(x_13); +x_14 = 1; +x_15 = lean_box(x_14); +lean_ctor_set(x_9, 0, x_15); +return x_9; +} +else +{ +lean_object* x_16; uint8_t x_17; lean_object* x_18; lean_object* x_19; +x_16 = lean_ctor_get(x_9, 1); +lean_inc(x_16); +lean_dec(x_9); +x_17 = 1; +x_18 = lean_box(x_17); +x_19 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_19, 0, x_18); +lean_ctor_set(x_19, 1, x_16); +return x_19; +} +} +else +{ +lean_object* x_20; size_t x_21; size_t x_22; +x_20 = lean_ctor_get(x_9, 1); +lean_inc(x_20); +lean_dec(x_9); +x_21 = 1; +x_22 = x_2 + x_21; +x_2 = x_22; +x_6 = x_20; +goto _start; +} +} +else +{ +uint8_t x_24; lean_object* x_25; lean_object* x_26; +x_24 = 0; +x_25 = lean_box(x_24); +x_26 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_26, 0, x_25); +lean_ctor_set(x_26, 1, x_6); +return x_26; +} +} +} +lean_object* l_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler(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; lean_object* x_7; lean_object* x_74; uint8_t x_75; +x_5 = lean_array_get_size(x_1); +x_74 = lean_unsigned_to_nat(0u); +x_75 = lean_nat_dec_lt(x_74, x_5); +if (x_75 == 0) +{ +uint8_t x_76; +x_76 = 1; +x_6 = x_76; +x_7 = x_4; +goto block_73; +} +else +{ +uint8_t x_77; +x_77 = lean_nat_dec_le(x_5, x_5); +if (x_77 == 0) +{ +uint8_t x_78; +x_78 = 1; +x_6 = x_78; +x_7 = x_4; +goto block_73; +} +else +{ +size_t x_79; size_t x_80; lean_object* x_81; lean_object* x_82; uint8_t x_83; +x_79 = 0; +x_80 = lean_usize_of_nat(x_5); +x_81 = l_Array_anyMUnsafe_any___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___spec__3(x_1, x_79, x_80, x_2, x_3, x_4); +x_82 = lean_ctor_get(x_81, 0); +lean_inc(x_82); +x_83 = lean_unbox(x_82); +lean_dec(x_82); +if (x_83 == 0) +{ +lean_object* x_84; uint8_t x_85; +x_84 = lean_ctor_get(x_81, 1); +lean_inc(x_84); +lean_dec(x_81); +x_85 = 1; +x_6 = x_85; +x_7 = x_84; +goto block_73; +} +else +{ +lean_object* x_86; uint8_t x_87; +x_86 = lean_ctor_get(x_81, 1); +lean_inc(x_86); +lean_dec(x_81); +x_87 = 0; +x_6 = x_87; +x_7 = x_86; +goto block_73; +} +} +} +block_73: +{ +if (x_6 == 0) +{ +uint8_t x_8; lean_object* x_9; lean_object* x_10; +lean_dec(x_5); +lean_dec(x_3); +lean_dec(x_2); +lean_dec(x_1); +x_8 = 0; +x_9 = lean_box(x_8); +x_10 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_10, 0, x_9); +lean_ctor_set(x_10, 1, x_7); +return x_10; +} +else +{ +lean_object* x_11; uint8_t x_12; +x_11 = lean_unsigned_to_nat(0u); +x_12 = lean_nat_dec_lt(x_11, x_5); +lean_dec(x_5); +if (x_12 == 0) +{ +uint8_t x_13; lean_object* x_14; lean_object* x_15; +lean_dec(x_3); +lean_dec(x_2); +lean_dec(x_1); +x_13 = 0; +x_14 = lean_box(x_13); +x_15 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_15, 0, x_14); +lean_ctor_set(x_15, 1, x_7); +return x_15; +} +else +{ +lean_object* x_16; lean_object* x_17; lean_object* x_18; +x_16 = lean_box(0); +x_17 = lean_alloc_closure((void*)(l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___boxed), 8, 1); +lean_closure_set(x_17, 0, x_1); +lean_inc(x_2); +x_18 = l_Lean_Elab_Command_liftTermElabM___rarg(x_16, x_17, x_2, x_3, x_7); +if (lean_obj_tag(x_18) == 0) +{ +uint8_t x_19; +x_19 = !lean_is_exclusive(x_18); +if (x_19 == 0) +{ +lean_object* x_20; lean_object* x_21; lean_object* x_22; uint8_t x_23; +x_20 = lean_ctor_get(x_18, 0); +x_21 = lean_ctor_get(x_18, 1); +x_22 = lean_array_get_size(x_20); +x_23 = lean_nat_dec_lt(x_11, x_22); +if (x_23 == 0) +{ +uint8_t x_24; lean_object* x_25; +lean_dec(x_22); +lean_dec(x_20); +lean_dec(x_3); +lean_dec(x_2); +x_24 = 1; +x_25 = lean_box(x_24); +lean_ctor_set(x_18, 0, x_25); +return x_18; +} +else +{ +uint8_t x_26; +x_26 = lean_nat_dec_le(x_22, x_22); +if (x_26 == 0) +{ +uint8_t x_27; lean_object* x_28; +lean_dec(x_22); +lean_dec(x_20); +lean_dec(x_3); +lean_dec(x_2); +x_27 = 1; +x_28 = lean_box(x_27); +lean_ctor_set(x_18, 0, x_28); +return x_18; +} +else +{ +size_t x_29; size_t x_30; lean_object* x_31; lean_object* x_32; +lean_free_object(x_18); +x_29 = 0; +x_30 = lean_usize_of_nat(x_22); +lean_dec(x_22); +x_31 = lean_box(0); +x_32 = l_Array_foldlMUnsafe_fold___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___spec__1(x_20, x_29, x_30, x_31, x_2, x_3, x_21); +lean_dec(x_2); +lean_dec(x_20); +if (lean_obj_tag(x_32) == 0) +{ +uint8_t x_33; +x_33 = !lean_is_exclusive(x_32); +if (x_33 == 0) +{ +lean_object* x_34; uint8_t x_35; lean_object* x_36; +x_34 = lean_ctor_get(x_32, 0); +lean_dec(x_34); +x_35 = 1; +x_36 = lean_box(x_35); +lean_ctor_set(x_32, 0, x_36); +return x_32; +} +else +{ +lean_object* x_37; uint8_t x_38; lean_object* x_39; lean_object* x_40; +x_37 = lean_ctor_get(x_32, 1); +lean_inc(x_37); +lean_dec(x_32); +x_38 = 1; +x_39 = lean_box(x_38); +x_40 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_40, 0, x_39); +lean_ctor_set(x_40, 1, x_37); +return x_40; +} +} +else +{ +uint8_t x_41; +x_41 = !lean_is_exclusive(x_32); +if (x_41 == 0) +{ +return x_32; +} +else +{ +lean_object* x_42; lean_object* x_43; lean_object* x_44; +x_42 = lean_ctor_get(x_32, 0); +x_43 = lean_ctor_get(x_32, 1); +lean_inc(x_43); +lean_inc(x_42); +lean_dec(x_32); +x_44 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_44, 0, x_42); +lean_ctor_set(x_44, 1, x_43); +return x_44; +} +} +} +} +} +else +{ +lean_object* x_45; lean_object* x_46; lean_object* x_47; uint8_t x_48; +x_45 = lean_ctor_get(x_18, 0); +x_46 = lean_ctor_get(x_18, 1); +lean_inc(x_46); +lean_inc(x_45); +lean_dec(x_18); +x_47 = lean_array_get_size(x_45); +x_48 = lean_nat_dec_lt(x_11, x_47); +if (x_48 == 0) +{ +uint8_t x_49; lean_object* x_50; lean_object* x_51; +lean_dec(x_47); +lean_dec(x_45); +lean_dec(x_3); +lean_dec(x_2); +x_49 = 1; +x_50 = lean_box(x_49); +x_51 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_51, 0, x_50); +lean_ctor_set(x_51, 1, x_46); +return x_51; +} +else +{ +uint8_t x_52; +x_52 = lean_nat_dec_le(x_47, x_47); +if (x_52 == 0) +{ +uint8_t x_53; lean_object* x_54; lean_object* x_55; +lean_dec(x_47); +lean_dec(x_45); +lean_dec(x_3); +lean_dec(x_2); +x_53 = 1; +x_54 = lean_box(x_53); +x_55 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_55, 0, x_54); +lean_ctor_set(x_55, 1, x_46); +return x_55; +} +else +{ +size_t x_56; size_t x_57; lean_object* x_58; lean_object* x_59; +x_56 = 0; +x_57 = lean_usize_of_nat(x_47); +lean_dec(x_47); +x_58 = lean_box(0); +x_59 = l_Array_foldlMUnsafe_fold___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___spec__1(x_45, x_56, x_57, x_58, x_2, x_3, x_46); +lean_dec(x_2); +lean_dec(x_45); +if (lean_obj_tag(x_59) == 0) +{ +lean_object* x_60; lean_object* x_61; uint8_t x_62; lean_object* x_63; lean_object* x_64; +x_60 = lean_ctor_get(x_59, 1); +lean_inc(x_60); +if (lean_is_exclusive(x_59)) { + lean_ctor_release(x_59, 0); + lean_ctor_release(x_59, 1); + x_61 = x_59; +} else { + lean_dec_ref(x_59); + x_61 = lean_box(0); +} +x_62 = 1; +x_63 = lean_box(x_62); +if (lean_is_scalar(x_61)) { + x_64 = lean_alloc_ctor(0, 2, 0); +} else { + x_64 = x_61; +} +lean_ctor_set(x_64, 0, x_63); +lean_ctor_set(x_64, 1, x_60); +return x_64; +} +else +{ +lean_object* x_65; lean_object* x_66; lean_object* x_67; lean_object* x_68; +x_65 = lean_ctor_get(x_59, 0); +lean_inc(x_65); +x_66 = lean_ctor_get(x_59, 1); +lean_inc(x_66); +if (lean_is_exclusive(x_59)) { + lean_ctor_release(x_59, 0); + lean_ctor_release(x_59, 1); + x_67 = x_59; +} else { + lean_dec_ref(x_59); + x_67 = lean_box(0); +} +if (lean_is_scalar(x_67)) { + x_68 = lean_alloc_ctor(1, 2, 0); +} else { + x_68 = x_67; +} +lean_ctor_set(x_68, 0, x_65); +lean_ctor_set(x_68, 1, x_66); +return x_68; +} +} +} +} +} +else +{ +uint8_t x_69; +lean_dec(x_3); +lean_dec(x_2); +x_69 = !lean_is_exclusive(x_18); +if (x_69 == 0) +{ +return x_18; +} +else +{ +lean_object* x_70; lean_object* x_71; lean_object* x_72; +x_70 = lean_ctor_get(x_18, 0); +x_71 = lean_ctor_get(x_18, 1); +lean_inc(x_71); +lean_inc(x_70); +lean_dec(x_18); +x_72 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_72, 0, x_70); +lean_ctor_set(x_72, 1, x_71); +return x_72; +} +} +} +} +} +} +} +lean_object* l_Array_foldlMUnsafe_fold___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___spec__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: +{ +size_t x_8; size_t x_9; lean_object* x_10; +x_8 = lean_unbox_usize(x_2); +lean_dec(x_2); +x_9 = lean_unbox_usize(x_3); +lean_dec(x_3); +x_10 = l_Array_foldlMUnsafe_fold___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___spec__1(x_1, x_8, x_9, x_4, x_5, x_6, x_7); +lean_dec(x_5); +lean_dec(x_1); +return x_10; +} +} +lean_object* l_Lean_isInductive___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___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_isInductive___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___spec__2(x_1, x_2, x_3, x_4); +lean_dec(x_3); +lean_dec(x_2); +return x_5; +} +} +lean_object* l_Array_anyMUnsafe_any___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___spec__3___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) { +_start: +{ +size_t x_7; size_t x_8; lean_object* x_9; +x_7 = lean_unbox_usize(x_2); +lean_dec(x_2); +x_8 = lean_unbox_usize(x_3); +lean_dec(x_3); +x_9 = l_Array_anyMUnsafe_any___at_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler___spec__3(x_1, x_7, x_8, x_4, x_5, x_6); +lean_dec(x_5); +lean_dec(x_4); +lean_dec(x_1); +return x_9; +} +} +static lean_object* _init_l_Lean_Elab_Deriving_Ord_initFn____x40_Lean_Elab_Deriving_Ord___hyg_2565____closed__1() { +_start: +{ +lean_object* x_1; +x_1 = lean_alloc_closure((void*)(l_Lean_Elab_Deriving_Ord_mkOrdInstanceHandler), 4, 0); +return x_1; +} +} +lean_object* l_Lean_Elab_Deriving_Ord_initFn____x40_Lean_Elab_Deriving_Ord___hyg_2565_(lean_object* x_1) { +_start: +{ +lean_object* x_2; lean_object* x_3; lean_object* x_4; +x_2 = l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg___closed__2; +x_3 = l_Lean_Elab_Deriving_Ord_initFn____x40_Lean_Elab_Deriving_Ord___hyg_2565____closed__1; +x_4 = l_Lean_Elab_registerBuiltinDerivingHandler(x_2, x_3, x_1); +if (lean_obj_tag(x_4) == 0) +{ +lean_object* x_5; lean_object* x_6; lean_object* x_7; +x_5 = lean_ctor_get(x_4, 1); +lean_inc(x_5); +lean_dec(x_4); +x_6 = l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___closed__2; +x_7 = l_Lean_registerTraceClass(x_6, x_5); +return x_7; +} +else +{ +uint8_t x_8; +x_8 = !lean_is_exclusive(x_4); +if (x_8 == 0) +{ +return x_4; +} +else +{ +lean_object* x_9; lean_object* x_10; lean_object* x_11; +x_9 = lean_ctor_get(x_4, 0); +x_10 = lean_ctor_get(x_4, 1); +lean_inc(x_10); +lean_inc(x_9); +lean_dec(x_4); +x_11 = lean_alloc_ctor(1, 2, 0); +lean_ctor_set(x_11, 0, x_9); +lean_ctor_set(x_11, 1, x_10); +return x_11; +} +} +} +} +lean_object* initialize_Init(lean_object*); +lean_object* initialize_Lean_Meta_Transform(lean_object*); +lean_object* initialize_Lean_Elab_Deriving_Basic(lean_object*); +lean_object* initialize_Lean_Elab_Deriving_Util(lean_object*); +static bool _G_initialized = false; +lean_object* initialize_Lean_Elab_Deriving_Ord(lean_object* w) { +lean_object * res; +if (_G_initialized) return lean_io_result_mk_ok(lean_box(0)); +_G_initialized = true; +res = initialize_Init(lean_io_mk_world()); +if (lean_io_result_is_error(res)) return res; +lean_dec_ref(res); +res = initialize_Lean_Meta_Transform(lean_io_mk_world()); +if (lean_io_result_is_error(res)) return res; +lean_dec_ref(res); +res = initialize_Lean_Elab_Deriving_Basic(lean_io_mk_world()); +if (lean_io_result_is_error(res)) return res; +lean_dec_ref(res); +res = initialize_Lean_Elab_Deriving_Util(lean_io_mk_world()); +if (lean_io_result_is_error(res)) return res; +lean_dec_ref(res); +l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg___closed__1 = _init_l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg___closed__1(); +lean_mark_persistent(l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg___closed__1); +l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg___closed__2 = _init_l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg___closed__2(); +lean_mark_persistent(l_Lean_Elab_Deriving_Ord_mkOrdHeader___rarg___closed__2); +l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__1 = _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__1(); +lean_mark_persistent(l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__1); +l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__2 = _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__2(); +lean_mark_persistent(l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__2); +l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__3 = _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__3(); +lean_mark_persistent(l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__3); +l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__4 = _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__4(); +lean_mark_persistent(l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__4); +l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__5 = _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__5(); +lean_mark_persistent(l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__5); +l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__6 = _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__6(); +lean_mark_persistent(l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__6); +l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__7 = _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__7(); +lean_mark_persistent(l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__7); +l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__8 = _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__8(); +lean_mark_persistent(l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__8); +l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__9 = _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__9(); +lean_mark_persistent(l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__9); +l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__10 = _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__10(); +lean_mark_persistent(l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__10); +l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__11 = _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__11(); +lean_mark_persistent(l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__11); +l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__12 = _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__12(); +lean_mark_persistent(l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__12); +l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__13 = _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__13(); +lean_mark_persistent(l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__13); +l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__14 = _init_l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__14(); +lean_mark_persistent(l_Std_Range_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__5___closed__14); +l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__1 = _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__1(); +lean_mark_persistent(l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__1); +l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__2 = _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__2(); +lean_mark_persistent(l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__2); +l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__3 = _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__3(); +lean_mark_persistent(l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__3); +l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__4 = _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__4(); +lean_mark_persistent(l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__4); +l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__5 = _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__5(); +lean_mark_persistent(l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__5); +l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__6 = _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__6(); +lean_mark_persistent(l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__6); +l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__7 = _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__7(); +lean_mark_persistent(l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__7); +l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__8 = _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__8(); +lean_mark_persistent(l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__8); +l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__9 = _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__9(); +lean_mark_persistent(l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__9); +l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__10 = _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__10(); +lean_mark_persistent(l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__10); +l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__11 = _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__11(); +lean_mark_persistent(l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__11); +l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__12 = _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__12(); +lean_mark_persistent(l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__12); +l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__13 = _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__13(); +lean_mark_persistent(l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__13); +l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__14 = _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__14(); +lean_mark_persistent(l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__14); +l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__15 = _init_l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__15(); +lean_mark_persistent(l_List_forIn_loop___at_Lean_Elab_Deriving_Ord_mkMatch_mkAlts___spec__7___lambda__1___closed__15); +l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__1 = _init_l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__1(); +lean_mark_persistent(l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__1); +l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__2 = _init_l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__2(); +lean_mark_persistent(l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__2); +l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__3 = _init_l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__3(); +lean_mark_persistent(l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__3); +l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__4 = _init_l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__4(); +lean_mark_persistent(l_Lean_Elab_Deriving_Ord_mkAuxFunction___lambda__1___closed__4); +l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___closed__1 = _init_l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___closed__1(); +lean_mark_persistent(l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___closed__1); +l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___closed__2 = _init_l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___closed__2(); +lean_mark_persistent(l___private_Lean_Elab_Deriving_Ord_0__Lean_Elab_Deriving_Ord_mkOrdInstanceCmds___closed__2); +l_Lean_Elab_Deriving_Ord_initFn____x40_Lean_Elab_Deriving_Ord___hyg_2565____closed__1 = _init_l_Lean_Elab_Deriving_Ord_initFn____x40_Lean_Elab_Deriving_Ord___hyg_2565____closed__1(); +lean_mark_persistent(l_Lean_Elab_Deriving_Ord_initFn____x40_Lean_Elab_Deriving_Ord___hyg_2565____closed__1); +res = l_Lean_Elab_Deriving_Ord_initFn____x40_Lean_Elab_Deriving_Ord___hyg_2565_(lean_io_mk_world()); +if (lean_io_result_is_error(res)) return res; +lean_dec_ref(res); +return lean_io_result_mk_ok(lean_box(0)); +} +#ifdef __cplusplus +} +#endif diff --git a/stage0/stdlib/Lean/Elab/InfoTree.c b/stage0/stdlib/Lean/Elab/InfoTree.c index 1c96b26c9c..6cf2783e46 100644 --- a/stage0/stdlib/Lean/Elab/InfoTree.c +++ b/stage0/stdlib/Lean/Elab/InfoTree.c @@ -2967,14 +2967,13 @@ return x_22; } case 1: { -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_23; lean_object* x_24; lean_object* x_25; lean_object* x_26; lean_object* x_27; lean_object* x_28; lean_object* x_29; lean_object* x_30; lean_object* x_31; lean_object* x_32; lean_object* x_33; lean_object* x_34; lean_object* x_35; lean_object* x_36; lean_object* x_37; lean_object* x_38; lean_object* x_39; lean_object* x_40; lean_object* x_41; x_23 = lean_ctor_get(x_2, 0); lean_inc(x_23); x_24 = lean_ctor_get(x_2, 1); lean_inc(x_24); x_25 = lean_ctor_get(x_2, 2); lean_inc(x_25); -lean_dec(x_2); x_26 = l_Std_fmt___at_Lean_Elab_CompletionInfo_format___spec__1(x_23); x_27 = l_Lean_Elab_CompletionInfo_format___closed__2; x_28 = lean_alloc_ctor(4, 2, 0); @@ -2989,35 +2988,56 @@ lean_dec(x_25); x_32 = lean_alloc_ctor(4, 2, 0); lean_ctor_set(x_32, 0, x_30); lean_ctor_set(x_32, 1, x_31); -x_33 = l_Std_Format_join___closed__1; +x_33 = l_Lean_Elab_TermInfo_format___lambda__1___closed__2; x_34 = lean_alloc_ctor(4, 2, 0); lean_ctor_set(x_34, 0, x_32); lean_ctor_set(x_34, 1, x_33); -x_35 = lean_alloc_closure((void*)(l_ReaderT_pure___at_Lean_Elab_CompletionInfo_format___spec__3___rarg___boxed), 6, 1); -lean_closure_set(x_35, 0, x_34); -x_36 = l_Lean_Elab_ContextInfo_runMetaM___rarg(x_1, x_24, x_35, x_3); +x_35 = l_Lean_Elab_CompletionInfo_stx(x_2); +lean_dec(x_2); +x_36 = l___private_Lean_Elab_InfoTree_0__Lean_Elab_formatStxRange(x_1, x_35); +lean_dec(x_35); +x_37 = lean_alloc_ctor(4, 2, 0); +lean_ctor_set(x_37, 0, x_34); +lean_ctor_set(x_37, 1, x_36); +x_38 = l_Std_Format_join___closed__1; +x_39 = lean_alloc_ctor(4, 2, 0); +lean_ctor_set(x_39, 0, x_37); +lean_ctor_set(x_39, 1, x_38); +x_40 = lean_alloc_closure((void*)(l_ReaderT_pure___at_Lean_Elab_CompletionInfo_format___spec__3___rarg___boxed), 6, 1); +lean_closure_set(x_40, 0, x_39); +x_41 = l_Lean_Elab_ContextInfo_runMetaM___rarg(x_1, x_24, x_40, x_3); lean_dec(x_1); -return x_36; +return x_41; } default: { -lean_object* x_37; lean_object* x_38; lean_object* x_39; lean_object* x_40; lean_object* x_41; lean_object* x_42; lean_object* x_43; -lean_dec(x_1); -x_37 = l_Lean_Elab_CompletionInfo_stx(x_2); +lean_object* x_42; lean_object* x_43; lean_object* x_44; lean_object* x_45; lean_object* x_46; lean_object* x_47; lean_object* x_48; lean_object* x_49; lean_object* x_50; lean_object* x_51; lean_object* x_52; +x_42 = l_Lean_Elab_CompletionInfo_stx(x_2); lean_dec(x_2); -x_38 = l_Std_fmt___at_Lean_Elab_CompletionInfo_format___spec__1(x_37); -x_39 = l_Lean_Elab_CompletionInfo_format___closed__2; -x_40 = lean_alloc_ctor(4, 2, 0); -lean_ctor_set(x_40, 0, x_39); -lean_ctor_set(x_40, 1, x_38); -x_41 = l_Std_Format_join___closed__1; -x_42 = lean_alloc_ctor(4, 2, 0); -lean_ctor_set(x_42, 0, x_40); -lean_ctor_set(x_42, 1, x_41); -x_43 = lean_alloc_ctor(0, 2, 0); -lean_ctor_set(x_43, 0, x_42); -lean_ctor_set(x_43, 1, x_3); -return x_43; +lean_inc(x_42); +x_43 = l_Std_fmt___at_Lean_Elab_CompletionInfo_format___spec__1(x_42); +x_44 = l_Lean_Elab_CompletionInfo_format___closed__2; +x_45 = lean_alloc_ctor(4, 2, 0); +lean_ctor_set(x_45, 0, x_44); +lean_ctor_set(x_45, 1, x_43); +x_46 = l_Lean_Elab_TermInfo_format___lambda__1___closed__2; +x_47 = lean_alloc_ctor(4, 2, 0); +lean_ctor_set(x_47, 0, x_45); +lean_ctor_set(x_47, 1, x_46); +x_48 = l___private_Lean_Elab_InfoTree_0__Lean_Elab_formatStxRange(x_1, x_42); +lean_dec(x_42); +lean_dec(x_1); +x_49 = lean_alloc_ctor(4, 2, 0); +lean_ctor_set(x_49, 0, x_47); +lean_ctor_set(x_49, 1, x_48); +x_50 = l_Std_Format_join___closed__1; +x_51 = lean_alloc_ctor(4, 2, 0); +lean_ctor_set(x_51, 0, x_49); +lean_ctor_set(x_51, 1, x_50); +x_52 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_52, 0, x_51); +lean_ctor_set(x_52, 1, x_3); +return x_52; } } } diff --git a/stage0/stdlib/Lean/Server/Completion.c b/stage0/stdlib/Lean/Server/Completion.c index 682cbf0aa9..8cec2b9b32 100644 --- a/stage0/stdlib/Lean/Server/Completion.c +++ b/stage0/stdlib/Lean/Server/Completion.c @@ -1,6 +1,6 @@ // Lean compiler output // Module: Lean.Server.Completion -// Imports: Init Lean.Environment Lean.Data.Lsp.LanguageFeatures Lean.Meta.Tactic.Apply Lean.Server.InfoUtils Lean.Parser.Extension +// Imports: Init Lean.Environment Lean.Data.Lsp.LanguageFeatures Lean.Meta.Tactic.Apply Lean.Meta.Match.MatcherInfo Lean.Server.InfoUtils Lean.Parser.Extension #include #if defined(__clang__) #pragma clang diagnostic ignored "-Wunused-parameter" @@ -188,6 +188,7 @@ lean_object* l_Std_PersistentHashMap_find_x3f___at_Lean_Parser_getCategory___spe lean_object* l_Std_PersistentHashMap_foldlM___at___private_Lean_Server_Completion_0__Lean_Server_Completion_idCompletionCore___spec__34(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_List_forIn_loop___at___private_Lean_Server_Completion_0__Lean_Server_Completion_idCompletionCore___spec__19___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* lean_format_pretty(lean_object*, lean_object*); +lean_object* l_Lean_Meta_isMatcher(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Std_PersistentHashMap_foldlMAux_traverse___at___private_Lean_Server_Completion_0__Lean_Server_Completion_dotCompletion___spec__8___rarg(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l___private_Lean_Server_Completion_0__Lean_Server_Completion_runM_match__1(lean_object*); lean_object* l___private_Lean_Server_Completion_0__Lean_Server_Completion_runM_match__1___rarg(lean_object*, lean_object*, lean_object*); @@ -584,187 +585,281 @@ return x_18; lean_object* l___private_Lean_Server_Completion_0__Lean_Server_Completion_isBlackListed(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6) { _start: { -lean_object* x_7; lean_object* x_8; lean_object* x_9; lean_object* x_10; lean_object* x_11; uint8_t x_12; +lean_object* x_7; uint8_t x_8; x_7 = lean_st_ref_get(x_5, x_6); -x_8 = lean_ctor_get(x_7, 0); -lean_inc(x_8); -x_9 = lean_ctor_get(x_7, 1); -lean_inc(x_9); -lean_dec(x_7); -x_10 = lean_ctor_get(x_8, 0); -lean_inc(x_10); -lean_dec(x_8); -lean_inc(x_1); -x_11 = l_Lean_isRec___at___private_Lean_Server_Completion_0__Lean_Server_Completion_isBlackListed___spec__1(x_1, x_2, x_3, x_4, x_5, x_9); -x_12 = !lean_is_exclusive(x_11); +x_8 = !lean_is_exclusive(x_7); +if (x_8 == 0) +{ +lean_object* x_9; lean_object* x_10; lean_object* x_11; uint8_t x_12; +x_9 = lean_ctor_get(x_7, 0); +x_10 = lean_ctor_get(x_7, 1); +x_11 = lean_ctor_get(x_9, 0); +lean_inc(x_11); +lean_dec(x_9); +x_12 = l_Lean_Name_isInternal(x_1); if (x_12 == 0) { lean_object* x_13; uint8_t x_14; -x_13 = lean_ctor_get(x_11, 0); -x_14 = l_Lean_Name_isInternal(x_1); +x_13 = l_Lean_auxRecExt; +x_14 = l_Lean_TagDeclarationExtension_isTagged(x_13, x_11, x_1); if (x_14 == 0) { lean_object* x_15; uint8_t x_16; -x_15 = l_Lean_auxRecExt; -x_16 = l_Lean_TagDeclarationExtension_isTagged(x_15, x_10, x_1); +x_15 = l_Lean_noConfusionExt; +x_16 = l_Lean_TagDeclarationExtension_isTagged(x_15, x_11, x_1); if (x_16 == 0) { -lean_object* x_17; uint8_t x_18; -x_17 = l_Lean_noConfusionExt; -x_18 = l_Lean_TagDeclarationExtension_isTagged(x_17, x_10, x_1); -if (x_18 == 0) -{ -uint8_t x_19; -x_19 = lean_unbox(x_13); -lean_dec(x_13); +lean_object* x_17; lean_object* x_18; uint8_t x_19; +lean_free_object(x_7); +lean_inc(x_1); +x_17 = l_Lean_isRec___at___private_Lean_Server_Completion_0__Lean_Server_Completion_isBlackListed___spec__1(x_1, x_2, x_3, x_4, x_5, x_10); +x_18 = lean_ctor_get(x_17, 0); +lean_inc(x_18); +x_19 = lean_unbox(x_18); if (x_19 == 0) { -lean_object* x_20; uint8_t x_21; lean_object* x_22; -x_20 = l_Lean_Server_Completion_completionBlackListExt; -x_21 = l_Lean_TagDeclarationExtension_isTagged(x_20, x_10, x_1); -lean_dec(x_1); -lean_dec(x_10); -x_22 = lean_box(x_21); -lean_ctor_set(x_11, 0, x_22); -return x_11; -} -else +uint8_t x_20; +lean_dec(x_18); +x_20 = !lean_is_exclusive(x_17); +if (x_20 == 0) { -uint8_t x_23; lean_object* x_24; -lean_dec(x_10); -lean_dec(x_1); -x_23 = 1; -x_24 = lean_box(x_23); -lean_ctor_set(x_11, 0, x_24); -return x_11; -} -} -else -{ -uint8_t x_25; lean_object* x_26; -lean_dec(x_13); -lean_dec(x_10); -lean_dec(x_1); -x_25 = 1; -x_26 = lean_box(x_25); -lean_ctor_set(x_11, 0, x_26); -return x_11; -} -} -else -{ -uint8_t x_27; lean_object* x_28; -lean_dec(x_13); -lean_dec(x_10); -lean_dec(x_1); -x_27 = 1; -x_28 = lean_box(x_27); -lean_ctor_set(x_11, 0, x_28); -return x_11; -} -} -else -{ -uint8_t x_29; lean_object* x_30; -lean_dec(x_13); -lean_dec(x_10); -lean_dec(x_1); -x_29 = 1; -x_30 = lean_box(x_29); -lean_ctor_set(x_11, 0, x_30); -return x_11; -} -} -else -{ -lean_object* x_31; lean_object* x_32; uint8_t x_33; -x_31 = lean_ctor_get(x_11, 0); -x_32 = lean_ctor_get(x_11, 1); -lean_inc(x_32); -lean_inc(x_31); +lean_object* x_21; lean_object* x_22; lean_object* x_23; uint8_t x_24; +x_21 = lean_ctor_get(x_17, 1); +x_22 = lean_ctor_get(x_17, 0); +lean_dec(x_22); +x_23 = l_Lean_Server_Completion_completionBlackListExt; +x_24 = l_Lean_TagDeclarationExtension_isTagged(x_23, x_11, x_1); lean_dec(x_11); -x_33 = l_Lean_Name_isInternal(x_1); +if (x_24 == 0) +{ +lean_object* x_25; +lean_free_object(x_17); +x_25 = l_Lean_Meta_isMatcher(x_1, x_2, x_3, x_4, x_5, x_21); +lean_dec(x_1); +return x_25; +} +else +{ +lean_object* x_26; +lean_dec(x_1); +x_26 = lean_box(x_24); +lean_ctor_set(x_17, 0, x_26); +return x_17; +} +} +else +{ +lean_object* x_27; lean_object* x_28; uint8_t x_29; +x_27 = lean_ctor_get(x_17, 1); +lean_inc(x_27); +lean_dec(x_17); +x_28 = l_Lean_Server_Completion_completionBlackListExt; +x_29 = l_Lean_TagDeclarationExtension_isTagged(x_28, x_11, x_1); +lean_dec(x_11); +if (x_29 == 0) +{ +lean_object* x_30; +x_30 = l_Lean_Meta_isMatcher(x_1, x_2, x_3, x_4, x_5, x_27); +lean_dec(x_1); +return x_30; +} +else +{ +lean_object* x_31; lean_object* x_32; +lean_dec(x_1); +x_31 = lean_box(x_29); +x_32 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_32, 0, x_31); +lean_ctor_set(x_32, 1, x_27); +return x_32; +} +} +} +else +{ +uint8_t x_33; +lean_dec(x_11); +lean_dec(x_1); +x_33 = !lean_is_exclusive(x_17); if (x_33 == 0) { -lean_object* x_34; uint8_t x_35; -x_34 = l_Lean_auxRecExt; -x_35 = l_Lean_TagDeclarationExtension_isTagged(x_34, x_10, x_1); -if (x_35 == 0) -{ -lean_object* x_36; uint8_t x_37; -x_36 = l_Lean_noConfusionExt; -x_37 = l_Lean_TagDeclarationExtension_isTagged(x_36, x_10, x_1); -if (x_37 == 0) -{ -uint8_t x_38; -x_38 = lean_unbox(x_31); -lean_dec(x_31); -if (x_38 == 0) -{ -lean_object* x_39; uint8_t x_40; lean_object* x_41; lean_object* x_42; -x_39 = l_Lean_Server_Completion_completionBlackListExt; -x_40 = l_Lean_TagDeclarationExtension_isTagged(x_39, x_10, x_1); -lean_dec(x_1); -lean_dec(x_10); -x_41 = lean_box(x_40); -x_42 = lean_alloc_ctor(0, 2, 0); -lean_ctor_set(x_42, 0, x_41); -lean_ctor_set(x_42, 1, x_32); -return x_42; +lean_object* x_34; +x_34 = lean_ctor_get(x_17, 0); +lean_dec(x_34); +return x_17; } else { -uint8_t x_43; lean_object* x_44; lean_object* x_45; -lean_dec(x_10); -lean_dec(x_1); -x_43 = 1; -x_44 = lean_box(x_43); -x_45 = lean_alloc_ctor(0, 2, 0); -lean_ctor_set(x_45, 0, x_44); -lean_ctor_set(x_45, 1, x_32); -return x_45; +lean_object* x_35; lean_object* x_36; +x_35 = lean_ctor_get(x_17, 1); +lean_inc(x_35); +lean_dec(x_17); +x_36 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_36, 0, x_18); +lean_ctor_set(x_36, 1, x_35); +return x_36; +} } } else { -uint8_t x_46; lean_object* x_47; lean_object* x_48; -lean_dec(x_31); -lean_dec(x_10); +lean_object* x_37; +lean_dec(x_11); lean_dec(x_1); -x_46 = 1; -x_47 = lean_box(x_46); -x_48 = lean_alloc_ctor(0, 2, 0); -lean_ctor_set(x_48, 0, x_47); -lean_ctor_set(x_48, 1, x_32); -return x_48; +x_37 = lean_box(x_16); +lean_ctor_set(x_7, 0, x_37); +return x_7; } } else { -uint8_t x_49; lean_object* x_50; lean_object* x_51; -lean_dec(x_31); -lean_dec(x_10); +lean_object* x_38; +lean_dec(x_11); lean_dec(x_1); -x_49 = 1; -x_50 = lean_box(x_49); -x_51 = lean_alloc_ctor(0, 2, 0); -lean_ctor_set(x_51, 0, x_50); -lean_ctor_set(x_51, 1, x_32); -return x_51; +x_38 = lean_box(x_14); +lean_ctor_set(x_7, 0, x_38); +return x_7; } } else { -uint8_t x_52; lean_object* x_53; lean_object* x_54; -lean_dec(x_31); -lean_dec(x_10); +lean_object* x_39; +lean_dec(x_11); lean_dec(x_1); -x_52 = 1; -x_53 = lean_box(x_52); -x_54 = lean_alloc_ctor(0, 2, 0); -lean_ctor_set(x_54, 0, x_53); -lean_ctor_set(x_54, 1, x_32); -return x_54; +x_39 = lean_box(x_12); +lean_ctor_set(x_7, 0, x_39); +return x_7; +} +} +else +{ +lean_object* x_40; lean_object* x_41; lean_object* x_42; uint8_t x_43; +x_40 = lean_ctor_get(x_7, 0); +x_41 = lean_ctor_get(x_7, 1); +lean_inc(x_41); +lean_inc(x_40); +lean_dec(x_7); +x_42 = lean_ctor_get(x_40, 0); +lean_inc(x_42); +lean_dec(x_40); +x_43 = l_Lean_Name_isInternal(x_1); +if (x_43 == 0) +{ +lean_object* x_44; uint8_t x_45; +x_44 = l_Lean_auxRecExt; +x_45 = l_Lean_TagDeclarationExtension_isTagged(x_44, x_42, x_1); +if (x_45 == 0) +{ +lean_object* x_46; uint8_t x_47; +x_46 = l_Lean_noConfusionExt; +x_47 = l_Lean_TagDeclarationExtension_isTagged(x_46, x_42, x_1); +if (x_47 == 0) +{ +lean_object* x_48; lean_object* x_49; uint8_t x_50; +lean_inc(x_1); +x_48 = l_Lean_isRec___at___private_Lean_Server_Completion_0__Lean_Server_Completion_isBlackListed___spec__1(x_1, x_2, x_3, x_4, x_5, x_41); +x_49 = lean_ctor_get(x_48, 0); +lean_inc(x_49); +x_50 = lean_unbox(x_49); +if (x_50 == 0) +{ +lean_object* x_51; lean_object* x_52; lean_object* x_53; uint8_t x_54; +lean_dec(x_49); +x_51 = lean_ctor_get(x_48, 1); +lean_inc(x_51); +if (lean_is_exclusive(x_48)) { + lean_ctor_release(x_48, 0); + lean_ctor_release(x_48, 1); + x_52 = x_48; +} else { + lean_dec_ref(x_48); + x_52 = lean_box(0); +} +x_53 = l_Lean_Server_Completion_completionBlackListExt; +x_54 = l_Lean_TagDeclarationExtension_isTagged(x_53, x_42, x_1); +lean_dec(x_42); +if (x_54 == 0) +{ +lean_object* x_55; +lean_dec(x_52); +x_55 = l_Lean_Meta_isMatcher(x_1, x_2, x_3, x_4, x_5, x_51); +lean_dec(x_1); +return x_55; +} +else +{ +lean_object* x_56; lean_object* x_57; +lean_dec(x_1); +x_56 = lean_box(x_54); +if (lean_is_scalar(x_52)) { + x_57 = lean_alloc_ctor(0, 2, 0); +} else { + x_57 = x_52; +} +lean_ctor_set(x_57, 0, x_56); +lean_ctor_set(x_57, 1, x_51); +return x_57; +} +} +else +{ +lean_object* x_58; lean_object* x_59; lean_object* x_60; +lean_dec(x_42); +lean_dec(x_1); +x_58 = lean_ctor_get(x_48, 1); +lean_inc(x_58); +if (lean_is_exclusive(x_48)) { + lean_ctor_release(x_48, 0); + lean_ctor_release(x_48, 1); + x_59 = x_48; +} else { + lean_dec_ref(x_48); + x_59 = lean_box(0); +} +if (lean_is_scalar(x_59)) { + x_60 = lean_alloc_ctor(0, 2, 0); +} else { + x_60 = x_59; +} +lean_ctor_set(x_60, 0, x_49); +lean_ctor_set(x_60, 1, x_58); +return x_60; +} +} +else +{ +lean_object* x_61; lean_object* x_62; +lean_dec(x_42); +lean_dec(x_1); +x_61 = lean_box(x_47); +x_62 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_62, 0, x_61); +lean_ctor_set(x_62, 1, x_41); +return x_62; +} +} +else +{ +lean_object* x_63; lean_object* x_64; +lean_dec(x_42); +lean_dec(x_1); +x_63 = lean_box(x_45); +x_64 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_64, 0, x_63); +lean_ctor_set(x_64, 1, x_41); +return x_64; +} +} +else +{ +lean_object* x_65; lean_object* x_66; +lean_dec(x_42); +lean_dec(x_1); +x_65 = lean_box(x_43); +x_66 = lean_alloc_ctor(0, 2, 0); +lean_ctor_set(x_66, 0, x_65); +lean_ctor_set(x_66, 1, x_41); +return x_66; } } } @@ -13862,6 +13957,7 @@ lean_object* initialize_Init(lean_object*); lean_object* initialize_Lean_Environment(lean_object*); lean_object* initialize_Lean_Data_Lsp_LanguageFeatures(lean_object*); lean_object* initialize_Lean_Meta_Tactic_Apply(lean_object*); +lean_object* initialize_Lean_Meta_Match_MatcherInfo(lean_object*); lean_object* initialize_Lean_Server_InfoUtils(lean_object*); lean_object* initialize_Lean_Parser_Extension(lean_object*); static bool _G_initialized = false; @@ -13881,6 +13977,9 @@ lean_dec_ref(res); res = initialize_Lean_Meta_Tactic_Apply(lean_io_mk_world()); if (lean_io_result_is_error(res)) return res; lean_dec_ref(res); +res = initialize_Lean_Meta_Match_MatcherInfo(lean_io_mk_world()); +if (lean_io_result_is_error(res)) return res; +lean_dec_ref(res); res = initialize_Lean_Server_InfoUtils(lean_io_mk_world()); if (lean_io_result_is_error(res)) return res; lean_dec_ref(res); diff --git a/stage0/stdlib/Lean/Server/FileWorker.c b/stage0/stdlib/Lean/Server/FileWorker.c index dd7b413de3..b71c1d69e9 100644 --- a/stage0/stdlib/Lean/Server/FileWorker.c +++ b/stage0/stdlib/Lean/Server/FileWorker.c @@ -19,7 +19,6 @@ lean_object* l_Lean_Server_FileWorker_leanpkgSetupSearchPath___closed__3; lean_object* l_ReaderT_pure___at_Lean_Server_FileWorker_handleCompletion___spec__1___rarg(lean_object*, lean_object*, lean_object*); lean_object* l_Lean_MapDeclarationExtension_find_x3f___at_Lean_findDeclarationRangesCore_x3f___spec__1(lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleWaitForDiagnostics___lambda__3(lean_object*, lean_object*); -uint8_t l_Lean_isRecCore(lean_object*, lean_object*); lean_object* lean_string_push(lean_object*, uint32_t); extern lean_object* l_Lean_Name_toString___closed__1; lean_object* l_IO_FS_Handle_readToEnd_read___at_IO_Process_output___spec__3(lean_object*, lean_object*, lean_object*); @@ -29,6 +28,7 @@ lean_object* l_Lean_Server_FileWorker_handleWaitForDiagnostics___lambda__1___box size_t l_USize_add(size_t, size_t); extern lean_object* l_Lean_Name_getString_x21___closed__3; lean_object* l_Lean_Server_FileWorker_handleSemanticTokensRange(lean_object*, lean_object*, lean_object*); +lean_object* l_Std_PersistentArray_forIn___at_Lean_Server_FileWorker_handleDefinition___spec__4___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_parseParams___at_Lean_Server_FileWorker_handleNotification___spec__1___boxed(lean_object*, lean_object*, lean_object*); lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleCompletion___spec__6___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_leanpkgSetupSearchPath___closed__5; @@ -80,6 +80,7 @@ lean_object* l___private_Lean_Data_Lsp_Extra_0__Lean_Lsp_fromJsonPlainGoalParams lean_object* l_IO_FS_Stream_writeLspResponse___at_Lean_Server_FileWorker_handleRequest___spec__7(lean_object*, lean_object*, lean_object*); lean_object* l_List_map___at_Lean_Server_FileWorker_handleDocumentSymbol___spec__1(lean_object*); lean_object* l_Array_append___rarg(lean_object*, lean_object*); +lean_object* l_Std_PersistentArray_forInAux___at_Lean_Server_FileWorker_handleDefinition___spec__5(uint8_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handlePlainGoal___spec__7(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, size_t, size_t, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleWaitForDiagnostics___lambda__3___closed__6; lean_object* l_String_split___at_Lean_stringToMessageData___spec__1(lean_object*); @@ -93,8 +94,10 @@ lean_object* l_Lean_Server_FileWorker_RequestError_fileChanged___closed__1; extern lean_object* l_Lean_Parser_Command_namedPrio___elambda__1___closed__2; lean_object* l_Lean_Server_FileWorker_handleDocumentHighlight___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); extern lean_object* l_Lean_Lsp_instFromJsonDiagnosticSeverity___closed__4; +lean_object* l_Std_PersistentArray_forInAux___at_Lean_Server_FileWorker_handleDefinition___spec__5___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_parseParams___at_Lean_Server_FileWorker_handleNotification___spec__2___boxed(lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleDocumentSymbol_toDocumentSymbols___lambda__4___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_findDeclarationRangesCore_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__3___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleSemanticTokens_highlightId_match__2(lean_object*); lean_object* lean_array_uset(lean_object*, size_t, lean_object*); extern lean_object* l_Lean_Lsp_Ipc_collectDiagnostics___closed__1; @@ -231,7 +234,7 @@ extern lean_object* l_Lean_Elab_parseImports___closed__1; extern lean_object* l_Lean_LocalContext_mkEmpty___closed__1; lean_object* l_IO_AsyncList_waitAll___rarg___lambda__1(lean_object*, lean_object*); lean_object* l_Std_PersistentArray_forIn___at_Lean_Server_FileWorker_handleCompletion___spec__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); -lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_initAndRunWorker___closed__2; lean_object* l_Array_mapMUnsafe_map___at___private_Lean_Server_FileWorker_0__Lean_Server_FileWorker_nextCmdSnap___spec__11(lean_object*, size_t, size_t, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_withWaitFindSnap(lean_object*); @@ -255,11 +258,9 @@ extern lean_object* l_Lean_maxRecDepth; lean_object* l_Lean_Server_FileWorker_compileHeader(lean_object*, lean_object*, lean_object*); lean_object* lean_io_bind_task(lean_object*, lean_object*, lean_object*, lean_object*); uint8_t l_Lean_Server_FileWorker_handleWaitForDiagnostics___lambda__1(lean_object*); -lean_object* l_Lean_findDeclarationRangesCore_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__4(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleRequest_match__2___rarg___closed__9; extern lean_object* l_Lean_JsonRpc_instToJsonMessage___closed__10; lean_object* l_Lean_Server_FileWorker_queueRequest___lambda__1(lean_object*, lean_object*, lean_object*); -lean_object* l_Std_PersistentArray_forIn___at_Lean_Server_FileWorker_handleDefinition___spec__5___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); extern lean_object* l_Lean_JsonRpc_instToJsonMessage___closed__5; lean_object* l_Lean_Server_FileWorker_handleRequest_match__2___rarg___closed__8; lean_object* l_Array_mapMUnsafe_map___at___private_Lean_Server_FileWorker_0__Lean_Server_FileWorker_nextCmdSnap___spec__4(lean_object*, size_t, size_t, lean_object*, lean_object*); @@ -268,7 +269,6 @@ lean_object* l_Lean_Server_FileWorker_updateDocument_match__1___rarg(lean_object lean_object* l_Lean_Server_FileWorker_initAndRunWorker_match__3___rarg(lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleNotification___boxed(lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_instInhabitedEditableDocument___closed__4; -lean_object* l_Lean_isRec___at_Lean_Server_FileWorker_handleDefinition___spec__3___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleWaitForDiagnostics___lambda__3___closed__4; lean_object* l_Lean_Json_toStructured_x3f___at___private_Lean_Server_FileWorker_0__Lean_Server_FileWorker_nextCmdSnap___spec__8(lean_object*); lean_object* l_IO_getStdin___at_Lean_Server_FileWorker_workerMain___spec__1(lean_object*); @@ -277,7 +277,6 @@ lean_object* l_Lean_Server_FileWorker_handleWaitForDiagnostics_waitLoop(lean_obj lean_object* l_Lean_Server_FileWorker_handleRequest___lambda__5(lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Std_PersistentArray_mapM___at___private_Lean_Server_FileWorker_0__Lean_Server_FileWorker_nextCmdSnap___spec__9___boxed__const__1; lean_object* l_Lean_Server_FileWorker_compileHeader___closed__2; -lean_object* l_Std_PersistentArray_forIn___at_Lean_Server_FileWorker_handleDefinition___spec__5(uint8_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleDocumentHighlight(lean_object*, lean_object*, lean_object*); lean_object* l_Std_RBNode_setBlack___rarg(lean_object*); extern lean_object* l___private_Lean_Data_Lsp_InitShutdown_0__Lean_Lsp_toJsonInitializeParams____x40_Lean_Data_Lsp_InitShutdown___hyg_222____closed__3; @@ -336,6 +335,7 @@ lean_object* l_Lean_Server_Snapshots_reparseHeader(lean_object*, lean_object*, l lean_object* l_List_mapM___at_Lean_Server_FileWorker_handlePlainGoal___spec__4___closed__1; extern lean_object* l_Lean_JsonRpc_instToJsonMessage___closed__7; lean_object* l_List_mapM___at_Lean_Server_FileWorker_leanpkgSetupSearchPath___spec__2(lean_object*, lean_object*); +lean_object* l_Lean_findDeclarationRangesCore_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__3(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Array_mapMUnsafe_map___at___private_Lean_Server_FileWorker_0__Lean_Server_FileWorker_nextCmdSnap___spec__4___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_IO_AsyncList_append___rarg(lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handlePlainGoal_match__2___rarg(lean_object*, lean_object*, lean_object*); @@ -355,6 +355,7 @@ lean_object* l_Lean_Server_FileWorker_handleSemanticTokensFull___rarg___boxed(le lean_object* l_Lean_Server_FileWorker_instInhabitedEditableDocument___closed__3; lean_object* l_ST_Prim_Ref_get___boxed(lean_object*, lean_object*, lean_object*, lean_object*); extern uint8_t l_Lean_expandExternPatternAux___closed__2; +lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleNotification_match__1___rarg___closed__1; lean_object* l_Lean_Server_FileWorker_handleDefinition___closed__2; lean_object* l_Lean_Server_FileWorker_unfoldCmdSnaps___lambda__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); @@ -382,7 +383,7 @@ extern lean_object* l_Lean_Lsp_Ipc_collectDiagnostics_loop_match__2___rarg___clo lean_object* l_Lean_Server_FileWorker_handleWaitForDiagnostics___lambda__3___closed__5; lean_object* l_Lean_Server_FileWorker_initAndRunWorker___boxed__const__1; lean_object* l_Lean_Server_FileWorker_handleSemanticTokens_highlightId_match__3___rarg(lean_object*, lean_object*, lean_object*); -lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7(uint8_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, size_t, size_t, lean_object*, lean_object*, lean_object*); +lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7(uint8_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, size_t, size_t, lean_object*, lean_object*, lean_object*); lean_object* lean_task_map(lean_object*, lean_object*, lean_object*); lean_object* l_Nat_repr(lean_object*); lean_object* l_List_getLast_x21___at_Lean_Server_FileWorker_handleDocumentSymbol_sectionLikeToDocumentSymbols___spec__1(lean_object*); @@ -399,10 +400,10 @@ lean_object* l_IO_FS_Stream_readNotificationAs___at_Lean_Server_FileWorker_initA lean_object* l_IO_FS_Stream_writeLspResponse___at_Lean_Server_FileWorker_handleRequest___spec__19___boxed(lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Syntax_getId(lean_object*); lean_object* l_Lean_Server_FileWorker_updateDocument___lambda__3___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); -lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* lean_format_pretty(lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_updateDocument___lambda__3___closed__1; extern lean_object* l_Lean_choiceKind; +lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_queueRequest___boxed(lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_compileHeader___lambda__1___closed__3; lean_object* l_Lean_Server_FileWorker_handleWaitForDiagnostics___lambda__3___closed__2; @@ -489,6 +490,7 @@ extern lean_object* l_Lean_Lsp_instToJsonWaitForDiagnostics___closed__1; extern lean_object* l___private_Lean_Data_Lsp_InitShutdown_0__Lean_Lsp_toJsonInitializeParams____x40_Lean_Data_Lsp_InitShutdown___hyg_222____closed__1; lean_object* l_Lean_Server_FileWorker_mainLoop(lean_object*, lean_object*); lean_object* l___private_Lean_Data_Lsp_LanguageFeatures_0__Lean_Lsp_fromJsonCompletionParams____x40_Lean_Data_Lsp_LanguageFeatures___hyg_302_(lean_object*); +lean_object* l_Std_PersistentArray_forIn___at_Lean_Server_FileWorker_handleDefinition___spec__4(uint8_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); extern lean_object* l_Task_Priority_default; lean_object* lean_io_has_finished(lean_object*, lean_object*); lean_object* l_Array_mapMUnsafe_map___at___private_Lean_Server_FileWorker_0__Lean_Server_FileWorker_nextCmdSnap___spec__11___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); @@ -496,6 +498,7 @@ lean_object* l_Lean_Server_FileWorker_handleDocumentSymbol_sectionLikeToDocument lean_object* l_Lean_Server_FileWorker_rangeOfSyntax(lean_object*, lean_object*); lean_object* l_List_mapM___at_Lean_Server_FileWorker_handlePlainGoal___spec__4(lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleDocumentSymbol_toDocumentSymbols___lambda__1(lean_object*, lean_object*, lean_object*); +lean_object* l_Lean_isRec___at___private_Lean_Server_Completion_0__Lean_Server_Completion_isBlackListed___spec__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); size_t lean_usize_of_nat(lean_object*); extern lean_object* l_Lean_nullKind___closed__1; lean_object* l_IO_AsyncList_waitFind_x3f___at_Lean_Server_FileWorker_withWaitFindSnap___spec__1___lambda__1(lean_object*, lean_object*, lean_object*); @@ -508,9 +511,7 @@ lean_object* l_Lean_Json_getObjValAs_x3f___at_Lean_Lsp_instFromJsonInitializePar lean_object* l_Lean_Server_FileWorker_handleDocumentSymbol_match__1(lean_object*); extern lean_object* l_Lean_Parser_Term_doReturn___elambda__1___closed__2; lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleCompletion___spec__5___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); -lean_object* l_Std_PersistentArray_forInAux___at_Lean_Server_FileWorker_handleDefinition___spec__6___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Std_PersistentArray_forIn___at_Lean_Server_FileWorker_handlePlainGoal___spec__5(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); -lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__9(uint8_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, size_t, size_t, lean_object*, lean_object*, lean_object*); lean_object* l___private_Lean_Server_AsyncList_0__IO_AsyncList_coeErr___at_Lean_Server_FileWorker_unfoldCmdSnaps___spec__3___lambda__1(lean_object*); lean_object* l_Lean_Server_FileWorker_handleNotification_match__1(lean_object*); lean_object* l_IO_mkRef___at_Lean_Server_FileWorker_CancelToken_new___spec__1(uint8_t, lean_object*); @@ -596,6 +597,7 @@ lean_object* l_Lean_Server_FileWorker_handleWaitForDiagnostics___lambda__3___clo lean_object* l_Std_PersistentArray_forInAux___at_Lean_Server_FileWorker_handleSemanticTokens_highlightId___spec__3___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleRequest_match__2___rarg___closed__2; extern lean_object* l_Lean_myMacro____x40_Init_NotationExtra___hyg_1139____closed__7; +lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleCompletion_match__2___rarg(lean_object*, lean_object*, lean_object*); uint8_t l_Std_RBNode_isRed___rarg(lean_object*); lean_object* l_Lean_Server_FileWorker_handleSemanticTokens___lambda__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); @@ -624,7 +626,6 @@ lean_object* l_Lean_addSearchPathFromEnv(lean_object*, lean_object*); lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handlePlainGoal___spec__9(lean_object*, lean_object*, lean_object*, lean_object*, size_t, size_t, lean_object*, lean_object*, lean_object*); lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleSemanticTokens_highlightId___spec__5___lambda__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*); lean_object* lean_get_stdout(lean_object*); -lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleDocumentSymbol_sectionLikeToDocumentSymbols(lean_object*, lean_object*, lean_object*, lean_object*, uint8_t, lean_object*); lean_object* l_Lean_Server_FileWorker_updateDocument(lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l___private_Lean_Server_FileWorker_0__Lean_Server_FileWorker_nextCmdSnap___closed__3; @@ -632,7 +633,6 @@ lean_object* l_Lean_findDeclarationRanges_x3f___at_Lean_Server_FileWorker_handle lean_object* l_Std_PersistentArray_forInAux___at_Lean_Server_FileWorker_handleSemanticTokens_highlightId___spec__3___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l___private_Lean_Data_Lsp_Communication_0__IO_FS_Stream_readLspHeader(lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_updateDocument_match__2___rarg(lean_object*, lean_object*); -lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); extern lean_object* l_Lean_JsonRpc_instToJsonErrorCode___closed__4; lean_object* l_Lean_Server_FileWorker_handleSemanticTokens_highlightId_match__1(lean_object*); extern lean_object* l_Lean_JsonRpc_instToJsonErrorCode___closed__40; @@ -640,7 +640,6 @@ lean_object* l_Lean_Server_FileWorker_leanpkgSetupSearchPath___closed__6; lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDocumentHighlight_highlightReturn_x3f___spec__3___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_parseParams___at_Lean_Server_FileWorker_handleRequest___spec__1(lean_object*, lean_object*, lean_object*); lean_object* l_Lean_findDeclarationRanges_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__2___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); -lean_object* l_Lean_isRec___at_Lean_Server_FileWorker_handleDefinition___spec__3(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Std_PersistentArray_forInAux___at_Lean_Server_FileWorker_handleHover___spec__2___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleDocumentSymbol_toDocumentSymbols___lambda__2(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_parseParams___at_Lean_Server_FileWorker_handleRequest___spec__1___boxed(lean_object*, lean_object*, lean_object*); @@ -728,15 +727,12 @@ lean_object* l_Lean_Server_FileWorker_handleRequest_match__2___rarg___closed__5; lean_object* l_Lean_Server_FileWorker_handleSemanticTokens(lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleWaitForDiagnostics(lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_updatePendingRequests(lean_object*, lean_object*, lean_object*); -lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__2___closed__1; lean_object* l_Lean_Server_FileWorker_handleSemanticTokens_highlightId_match__2___rarg(lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_IO_FS_Stream_writeLspResponse___at_Lean_Server_FileWorker_handleRequest___spec__17(lean_object*, lean_object*, lean_object*); -lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__2___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleWaitForDiagnostics___lambda__4(lean_object*); lean_object* l_Lean_Server_FileWorker_handleHover_match__3(lean_object*); lean_object* l_ReaderT_pure___at_Lean_Server_FileWorker_handleCompletion___spec__1___rarg___boxed(lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_unfoldCmdSnaps(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); -lean_object* l_Std_PersistentArray_forInAux___at_Lean_Server_FileWorker_handleDefinition___spec__6(uint8_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleHover___spec__4(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, size_t, size_t, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleHover___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_CancelToken_set(lean_object*, lean_object*); @@ -755,7 +751,6 @@ lean_object* l_Lean_Server_FileWorker_handleSemanticTokens___lambda__2___closed_ lean_object* l_Lean_Server_FileWorker_parseParams___rarg(lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Elab_Info_pos_x3f(lean_object*); lean_object* l_Lean_Server_FileWorker_handleNotification_match__1___rarg(lean_object*, lean_object*, lean_object*, lean_object*); -lean_object* l_Lean_findDeclarationRangesCore_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__4___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_ReaderT_pure___at_Lean_Server_FileWorker_handleCompletion___spec__1(lean_object*); extern lean_object* l_IO_instInhabitedError; lean_object* l_Lean_Server_FileWorker_handleDocumentSymbol___rarg(lean_object*, lean_object*); @@ -774,13 +769,17 @@ extern lean_object* l_System_FilePath_exeSuffix; uint8_t l_List_isEmpty___rarg(lean_object*); lean_object* l_List_lengthAux___rarg(lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleWaitForDiagnostics_waitLoop___boxed(lean_object*, lean_object*, lean_object*); +lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__6(uint8_t, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, size_t, size_t, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handlePlainGoal_match__3(lean_object*); lean_object* l_Lean_Server_FileWorker_handleDocumentSymbol_toDocumentSymbols___closed__2; lean_object* l___private_Lean_Data_Lsp_TextSync_0__Lean_Lsp_fromJsonDidChangeTextDocumentParams____x40_Lean_Data_Lsp_TextSync___hyg_309_(lean_object*); lean_object* l_Lean_Server_FileWorker_handlePlainGoal___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); extern lean_object* l_Lean_JsonRpc_instToJsonErrorCode___closed__12; extern lean_object* l___private_Lean_Data_Lsp_Basic_0__Lean_Lsp_toJsonRange____x40_Lean_Data_Lsp_Basic___hyg_361____closed__1; +lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__2___closed__1; lean_object* l_Lean_Server_FileWorker_withWaitFindSnap___rarg___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__2___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); +lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__6___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleDocumentSymbol_sectionLikeToDocumentSymbols_match__1___rarg(lean_object*, lean_object*, lean_object*); lean_object* l_List_getLast_x21___at_Lean_Server_FileWorker_updateDocument___spec__1(lean_object*); lean_object* l_Lean_Server_FileWorker_workerMain___boxed__const__1; @@ -836,7 +835,6 @@ lean_object* l_Lean_Server_FileWorker_handleDefinition_match__4___rarg(lean_obje lean_object* l_Lean_Server_Snapshots_compileNextCmd(lean_object*, lean_object*, lean_object*); lean_object* l_List_forIn_loop___at_Lean_Server_FileWorker_handleSemanticTokens___spec__2___lambda__1(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); extern lean_object* l_term_x5b___x5d___closed__3; -lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__9___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Lean_findModuleOf_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__1___boxed(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); lean_object* l_Std_PersistentArray_mapM___at___private_Lean_Server_FileWorker_0__Lean_Server_FileWorker_nextCmdSnap___spec__9(lean_object*, lean_object*, lean_object*); lean_object* l_Lean_Server_FileWorker_handleRequest_match__2___rarg(lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*, lean_object*); @@ -14314,45 +14312,7 @@ return x_64; } } } -lean_object* l_Lean_isRec___at_Lean_Server_FileWorker_handleDefinition___spec__3(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6) { -_start: -{ -lean_object* x_7; uint8_t x_8; -x_7 = lean_st_ref_get(x_5, x_6); -x_8 = !lean_is_exclusive(x_7); -if (x_8 == 0) -{ -lean_object* x_9; lean_object* x_10; uint8_t x_11; lean_object* x_12; -x_9 = lean_ctor_get(x_7, 0); -x_10 = lean_ctor_get(x_9, 0); -lean_inc(x_10); -lean_dec(x_9); -x_11 = l_Lean_isRecCore(x_10, x_1); -x_12 = lean_box(x_11); -lean_ctor_set(x_7, 0, x_12); -return x_7; -} -else -{ -lean_object* x_13; lean_object* x_14; lean_object* x_15; uint8_t x_16; lean_object* x_17; lean_object* x_18; -x_13 = lean_ctor_get(x_7, 0); -x_14 = lean_ctor_get(x_7, 1); -lean_inc(x_14); -lean_inc(x_13); -lean_dec(x_7); -x_15 = lean_ctor_get(x_13, 0); -lean_inc(x_15); -lean_dec(x_13); -x_16 = l_Lean_isRecCore(x_15, x_1); -x_17 = lean_box(x_16); -x_18 = lean_alloc_ctor(0, 2, 0); -lean_ctor_set(x_18, 0, x_17); -lean_ctor_set(x_18, 1, x_14); -return x_18; -} -} -} -lean_object* l_Lean_findDeclarationRangesCore_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__4(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* l_Lean_findDeclarationRangesCore_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__3(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6) { _start: { lean_object* x_7; uint8_t x_8; @@ -14406,7 +14366,7 @@ x_10 = lean_ctor_get(x_8, 0); lean_inc(x_10); lean_dec(x_8); lean_inc(x_1); -x_11 = l_Lean_isRec___at_Lean_Server_FileWorker_handleDefinition___spec__3(x_1, x_2, x_3, x_4, x_5, x_9); +x_11 = l_Lean_isRec___at___private_Lean_Server_Completion_0__Lean_Server_Completion_isBlackListed___spec__1(x_1, x_2, x_3, x_4, x_5, x_9); x_12 = lean_ctor_get(x_11, 0); lean_inc(x_12); x_13 = lean_ctor_get(x_11, 1); @@ -14428,7 +14388,7 @@ lean_dec(x_12); if (x_18 == 0) { lean_object* x_19; -x_19 = l_Lean_findDeclarationRangesCore_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__4(x_1, x_2, x_3, x_4, x_5, x_13); +x_19 = l_Lean_findDeclarationRangesCore_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__3(x_1, x_2, x_3, x_4, x_5, x_13); return x_19; } else @@ -14436,7 +14396,7 @@ else lean_object* x_20; lean_object* x_21; x_20 = l_Lean_Name_getPrefix(x_1); lean_dec(x_1); -x_21 = l_Lean_findDeclarationRangesCore_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__4(x_20, x_2, x_3, x_4, x_5, x_13); +x_21 = l_Lean_findDeclarationRangesCore_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__3(x_20, x_2, x_3, x_4, x_5, x_13); return x_21; } } @@ -14446,7 +14406,7 @@ lean_object* x_22; lean_object* x_23; lean_dec(x_12); x_22 = l_Lean_Name_getPrefix(x_1); lean_dec(x_1); -x_23 = l_Lean_findDeclarationRangesCore_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__4(x_22, x_2, x_3, x_4, x_5, x_13); +x_23 = l_Lean_findDeclarationRangesCore_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__3(x_22, x_2, x_3, x_4, x_5, x_13); return x_23; } } @@ -14457,12 +14417,12 @@ lean_dec(x_12); lean_dec(x_10); x_24 = l_Lean_Name_getPrefix(x_1); lean_dec(x_1); -x_25 = l_Lean_findDeclarationRangesCore_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__4(x_24, x_2, x_3, x_4, x_5, x_13); +x_25 = l_Lean_findDeclarationRangesCore_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__3(x_24, x_2, x_3, x_4, x_5, x_13); return x_25; } } } -lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7(uint8_t x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6, lean_object* x_7, lean_object* x_8, lean_object* x_9, size_t x_10, size_t x_11, lean_object* x_12, lean_object* x_13, lean_object* x_14) { +lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__6(uint8_t x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6, lean_object* x_7, lean_object* x_8, lean_object* x_9, size_t x_10, size_t x_11, lean_object* x_12, lean_object* x_13, lean_object* x_14) { _start: { lean_object* x_15; lean_object* x_16; uint8_t x_39; @@ -14489,7 +14449,7 @@ lean_inc(x_43); lean_dec(x_12); lean_inc(x_6); lean_inc(x_5); -x_44 = l_Std_PersistentArray_forInAux___at_Lean_Server_FileWorker_handleDefinition___spec__6(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_42, x_43, x_13, x_14); +x_44 = l_Std_PersistentArray_forInAux___at_Lean_Server_FileWorker_handleDefinition___spec__5(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_42, x_43, x_13, x_14); lean_dec(x_42); if (lean_obj_tag(x_44) == 0) { @@ -14785,7 +14745,7 @@ goto _start; } } } -lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___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_object* x_8, lean_object* x_9) { +lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___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_object* x_8, lean_object* x_9) { _start: { lean_object* x_10; lean_object* x_11; @@ -15152,7 +15112,7 @@ return x_115; } } } -static lean_object* _init_l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__2___closed__1() { +static lean_object* _init_l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__2___closed__1() { _start: { lean_object* x_1; @@ -15160,7 +15120,7 @@ x_1 = lean_mk_string(".lean"); return x_1; } } -lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__2(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6, lean_object* x_7, lean_object* x_8, lean_object* x_9) { +lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__2(lean_object* x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6, lean_object* x_7, lean_object* x_8, lean_object* x_9) { _start: { lean_object* x_10; @@ -15207,7 +15167,7 @@ lean_dec(x_18); x_21 = lean_ctor_get(x_5, 0); lean_inc(x_21); lean_ctor_set(x_10, 0, x_21); -x_22 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__1(x_15, x_3, x_16, x_1, x_2, x_4, x_10, x_8, x_20); +x_22 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__1(x_15, x_3, x_16, x_1, x_2, x_4, x_10, x_8, x_20); lean_dec(x_2); return x_22; } @@ -15222,7 +15182,7 @@ x_24 = lean_ctor_get(x_19, 0); lean_inc(x_24); lean_dec(x_19); x_25 = lean_ctor_get(x_6, 3); -x_26 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__2___closed__1; +x_26 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__2___closed__1; x_27 = l_Lean_SearchPath_findWithExt(x_25, x_26, x_24, x_23); lean_dec(x_24); if (lean_obj_tag(x_27) == 0) @@ -15237,7 +15197,7 @@ x_29 = lean_ctor_get(x_27, 1); lean_inc(x_29); lean_dec(x_27); x_30 = lean_box(0); -x_31 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__1(x_15, x_3, x_16, x_1, x_2, x_4, x_30, x_8, x_29); +x_31 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__1(x_15, x_3, x_16, x_1, x_2, x_4, x_30, x_8, x_29); lean_dec(x_2); return x_31; } @@ -15254,7 +15214,7 @@ lean_object* x_34; lean_object* x_35; lean_object* x_36; x_34 = lean_ctor_get(x_28, 0); x_35 = l_Lean_Server_toFileUri(x_34); lean_ctor_set(x_28, 0, x_35); -x_36 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__1(x_15, x_3, x_16, x_1, x_2, x_4, x_28, x_8, x_32); +x_36 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__1(x_15, x_3, x_16, x_1, x_2, x_4, x_28, x_8, x_32); lean_dec(x_2); return x_36; } @@ -15267,7 +15227,7 @@ lean_dec(x_28); x_38 = l_Lean_Server_toFileUri(x_37); x_39 = lean_alloc_ctor(1, 1, 0); lean_ctor_set(x_39, 0, x_38); -x_40 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__1(x_15, x_3, x_16, x_1, x_2, x_4, x_39, x_8, x_32); +x_40 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__1(x_15, x_3, x_16, x_1, x_2, x_4, x_39, x_8, x_32); lean_dec(x_2); return x_40; } @@ -15357,7 +15317,7 @@ x_55 = lean_ctor_get(x_5, 0); lean_inc(x_55); x_56 = lean_alloc_ctor(1, 1, 0); lean_ctor_set(x_56, 0, x_55); -x_57 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__1(x_49, x_3, x_50, x_1, x_2, x_4, x_56, x_8, x_54); +x_57 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__1(x_49, x_3, x_50, x_1, x_2, x_4, x_56, x_8, x_54); lean_dec(x_2); return x_57; } @@ -15371,7 +15331,7 @@ x_59 = lean_ctor_get(x_53, 0); lean_inc(x_59); lean_dec(x_53); x_60 = lean_ctor_get(x_6, 3); -x_61 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__2___closed__1; +x_61 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__2___closed__1; x_62 = l_Lean_SearchPath_findWithExt(x_60, x_61, x_59, x_58); lean_dec(x_59); if (lean_obj_tag(x_62) == 0) @@ -15386,7 +15346,7 @@ x_64 = lean_ctor_get(x_62, 1); lean_inc(x_64); lean_dec(x_62); x_65 = lean_box(0); -x_66 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__1(x_49, x_3, x_50, x_1, x_2, x_4, x_65, x_8, x_64); +x_66 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__1(x_49, x_3, x_50, x_1, x_2, x_4, x_65, x_8, x_64); lean_dec(x_2); return x_66; } @@ -15412,7 +15372,7 @@ if (lean_is_scalar(x_69)) { x_71 = x_69; } lean_ctor_set(x_71, 0, x_70); -x_72 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__1(x_49, x_3, x_50, x_1, x_2, x_4, x_71, x_8, x_67); +x_72 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__1(x_49, x_3, x_50, x_1, x_2, x_4, x_71, x_8, x_67); lean_dec(x_2); return x_72; } @@ -15479,7 +15439,7 @@ return x_80; } } } -lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8(uint8_t 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, size_t x_9, size_t x_10, lean_object* x_11, lean_object* x_12, lean_object* x_13) { +lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7(uint8_t 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, size_t x_9, size_t x_10, lean_object* x_11, lean_object* x_12, lean_object* x_13) { _start: { lean_object* x_14; lean_object* x_15; lean_object* x_38; lean_object* x_39; uint8_t x_67; @@ -15538,7 +15498,7 @@ lean_dec(x_75); x_78 = lean_ctor_get(x_77, 1); lean_inc(x_78); lean_inc(x_6); -x_79 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__2(x_6, x_77, x_76, x_4, x_3, x_2, x_78, x_12, x_13); +x_79 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__2(x_6, x_77, x_76, x_4, x_3, x_2, x_78, x_12, x_13); lean_dec(x_78); lean_dec(x_76); if (lean_obj_tag(x_79) == 0) @@ -15604,7 +15564,7 @@ x_93 = lean_ctor_get(x_91, 1); lean_inc(x_93); lean_dec(x_91); lean_inc(x_6); -x_94 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__2(x_6, x_87, x_86, x_4, x_3, x_2, x_92, x_12, x_93); +x_94 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__2(x_6, x_87, x_86, x_4, x_3, x_2, x_92, x_12, x_93); lean_dec(x_92); lean_dec(x_86); if (lean_obj_tag(x_94) == 0) @@ -15940,7 +15900,7 @@ goto block_37; } } } -lean_object* l_Std_PersistentArray_forInAux___at_Lean_Server_FileWorker_handleDefinition___spec__6(uint8_t x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6, lean_object* x_7, lean_object* x_8, lean_object* x_9, lean_object* x_10, lean_object* x_11) { +lean_object* l_Std_PersistentArray_forInAux___at_Lean_Server_FileWorker_handleDefinition___spec__5(uint8_t x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6, lean_object* x_7, lean_object* x_8, lean_object* x_9, lean_object* x_10, lean_object* x_11) { _start: { if (lean_obj_tag(x_8) == 0) @@ -15955,7 +15915,7 @@ x_15 = lean_array_get_size(x_12); x_16 = lean_usize_of_nat(x_15); lean_dec(x_15); x_17 = 0; -x_18 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_13, x_12, x_16, x_17, x_14, x_10, x_11); +x_18 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__6(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_13, x_12, x_16, x_17, x_14, x_10, x_11); if (lean_obj_tag(x_18) == 0) { lean_object* x_19; @@ -16158,7 +16118,7 @@ x_61 = lean_array_get_size(x_58); x_62 = lean_usize_of_nat(x_61); lean_dec(x_61); x_63 = 0; -x_64 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8(x_1, x_2, x_3, x_4, x_5, x_6, x_59, x_58, x_62, x_63, x_60, x_10, x_11); +x_64 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7(x_1, x_2, x_3, x_4, x_5, x_6, x_59, x_58, x_62, x_63, x_60, x_10, x_11); if (lean_obj_tag(x_64) == 0) { lean_object* x_65; @@ -16351,7 +16311,7 @@ return x_103; } } } -lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__9(uint8_t 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, size_t x_9, size_t x_10, lean_object* x_11, lean_object* x_12, lean_object* x_13) { +lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8(uint8_t 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, size_t x_9, size_t x_10, lean_object* x_11, lean_object* x_12, lean_object* x_13) { _start: { lean_object* x_14; lean_object* x_15; lean_object* x_38; lean_object* x_39; uint8_t x_72; @@ -16410,7 +16370,7 @@ lean_dec(x_80); x_83 = lean_ctor_get(x_82, 1); lean_inc(x_83); lean_inc(x_6); -x_84 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__2(x_6, x_82, x_81, x_4, x_3, x_2, x_83, x_12, x_13); +x_84 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__2(x_6, x_82, x_81, x_4, x_3, x_2, x_83, x_12, x_13); lean_dec(x_83); lean_dec(x_81); if (lean_obj_tag(x_84) == 0) @@ -16476,7 +16436,7 @@ x_98 = lean_ctor_get(x_96, 1); lean_inc(x_98); lean_dec(x_96); lean_inc(x_6); -x_99 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__2(x_6, x_92, x_91, x_4, x_3, x_2, x_97, x_12, x_98); +x_99 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__2(x_6, x_92, x_91, x_4, x_3, x_2, x_97, x_12, x_98); lean_dec(x_97); lean_dec(x_91); if (lean_obj_tag(x_99) == 0) @@ -16846,7 +16806,7 @@ goto block_37; } } } -lean_object* l_Std_PersistentArray_forIn___at_Lean_Server_FileWorker_handleDefinition___spec__5(uint8_t x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6, lean_object* x_7, lean_object* x_8, lean_object* x_9, lean_object* x_10) { +lean_object* l_Std_PersistentArray_forIn___at_Lean_Server_FileWorker_handleDefinition___spec__4(uint8_t x_1, lean_object* x_2, lean_object* x_3, lean_object* x_4, lean_object* x_5, lean_object* x_6, lean_object* x_7, lean_object* x_8, lean_object* x_9, lean_object* x_10) { _start: { lean_object* x_11; lean_object* x_12; @@ -16854,7 +16814,7 @@ x_11 = lean_ctor_get(x_7, 0); lean_inc(x_8); lean_inc(x_6); lean_inc(x_5); -x_12 = l_Std_PersistentArray_forInAux___at_Lean_Server_FileWorker_handleDefinition___spec__6(x_1, x_2, x_3, x_4, x_5, x_6, x_8, x_11, x_8, x_9, x_10); +x_12 = l_Std_PersistentArray_forInAux___at_Lean_Server_FileWorker_handleDefinition___spec__5(x_1, x_2, x_3, x_4, x_5, x_6, x_8, x_11, x_8, x_9, x_10); lean_dec(x_8); if (lean_obj_tag(x_12) == 0) { @@ -16976,7 +16936,7 @@ x_37 = lean_array_get_size(x_34); x_38 = lean_usize_of_nat(x_37); lean_dec(x_37); x_39 = 0; -x_40 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__9(x_1, x_2, x_3, x_4, x_5, x_6, x_35, x_34, x_38, x_39, x_36, x_9, x_32); +x_40 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8(x_1, x_2, x_3, x_4, x_5, x_6, x_35, x_34, x_38, x_39, x_36, x_9, x_32); if (lean_obj_tag(x_40) == 0) { lean_object* x_41; @@ -17221,7 +17181,7 @@ x_91 = lean_array_get_size(x_88); x_92 = lean_usize_of_nat(x_91); lean_dec(x_91); x_93 = 0; -x_94 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__9(x_1, x_2, x_3, x_4, x_5, x_6, x_89, x_88, x_92, x_93, x_90, x_9, x_86); +x_94 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8(x_1, x_2, x_3, x_4, x_5, x_6, x_89, x_88, x_92, x_93, x_90, x_9, x_86); if (lean_obj_tag(x_94) == 0) { lean_object* x_95; @@ -17392,7 +17352,7 @@ x_12 = lean_ctor_get(x_11, 1); lean_inc(x_12); lean_dec(x_11); x_13 = l_Array_findSomeM_x3f___rarg___closed__1; -x_14 = l_Std_PersistentArray_forIn___at_Lean_Server_FileWorker_handleDefinition___spec__5(x_1, x_2, x_3, x_4, x_5, x_13, x_12, x_13, x_8, x_9); +x_14 = l_Std_PersistentArray_forIn___at_Lean_Server_FileWorker_handleDefinition___spec__4(x_1, x_2, x_3, x_4, x_5, x_13, x_12, x_13, x_8, x_9); lean_dec(x_12); if (lean_obj_tag(x_14) == 0) { @@ -17680,23 +17640,11 @@ lean_dec(x_2); return x_7; } } -lean_object* l_Lean_isRec___at_Lean_Server_FileWorker_handleDefinition___spec__3___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* l_Lean_findDeclarationRangesCore_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__3___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) { _start: { lean_object* x_7; -x_7 = l_Lean_isRec___at_Lean_Server_FileWorker_handleDefinition___spec__3(x_1, x_2, x_3, x_4, x_5, x_6); -lean_dec(x_5); -lean_dec(x_4); -lean_dec(x_3); -lean_dec(x_2); -return x_7; -} -} -lean_object* l_Lean_findDeclarationRangesCore_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__4___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) { -_start: -{ -lean_object* x_7; -x_7 = l_Lean_findDeclarationRangesCore_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__4(x_1, x_2, x_3, x_4, x_5, x_6); +x_7 = l_Lean_findDeclarationRangesCore_x3f___at_Lean_Server_FileWorker_handleDefinition___spec__3(x_1, x_2, x_3, x_4, x_5, x_6); lean_dec(x_5); lean_dec(x_4); lean_dec(x_3); @@ -17716,7 +17664,7 @@ lean_dec(x_2); return x_7; } } -lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___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, lean_object* x_9, lean_object* x_10, lean_object* x_11, lean_object* x_12, lean_object* x_13, lean_object* x_14) { +lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__6___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, lean_object* x_9, lean_object* x_10, lean_object* x_11, lean_object* x_12, lean_object* x_13, lean_object* x_14) { _start: { uint8_t x_15; size_t x_16; size_t x_17; lean_object* x_18; @@ -17726,7 +17674,7 @@ x_16 = lean_unbox_usize(x_10); lean_dec(x_10); x_17 = lean_unbox_usize(x_11); lean_dec(x_11); -x_18 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7(x_15, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9, x_16, x_17, x_12, x_13, x_14); +x_18 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__6(x_15, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9, x_16, x_17, x_12, x_13, x_14); lean_dec(x_13); lean_dec(x_9); lean_dec(x_7); @@ -17736,11 +17684,11 @@ lean_dec(x_2); return x_18; } } -lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___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_object* x_8, lean_object* x_9) { +lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___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_object* x_8, lean_object* x_9) { _start: { lean_object* x_10; -x_10 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__1(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9); +x_10 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__1(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9); lean_dec(x_8); lean_dec(x_6); lean_dec(x_5); @@ -17748,11 +17696,11 @@ lean_dec(x_2); return x_10; } } -lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__2___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, lean_object* x_9) { +lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__2___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, lean_object* x_9) { _start: { lean_object* x_10; -x_10 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__2(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9); +x_10 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__2(x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9); lean_dec(x_8); lean_dec(x_7); lean_dec(x_6); @@ -17762,6 +17710,41 @@ lean_dec(x_3); return x_10; } } +lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___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, lean_object* x_9, lean_object* x_10, lean_object* x_11, lean_object* x_12, lean_object* x_13) { +_start: +{ +uint8_t x_14; size_t x_15; size_t x_16; lean_object* x_17; +x_14 = lean_unbox(x_1); +lean_dec(x_1); +x_15 = lean_unbox_usize(x_9); +lean_dec(x_9); +x_16 = lean_unbox_usize(x_10); +lean_dec(x_10); +x_17 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7(x_14, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_15, x_16, x_11, x_12, x_13); +lean_dec(x_12); +lean_dec(x_8); +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_2); +return x_17; +} +} +lean_object* l_Std_PersistentArray_forInAux___at_Lean_Server_FileWorker_handleDefinition___spec__5___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, lean_object* x_9, lean_object* x_10, lean_object* x_11) { +_start: +{ +uint8_t x_12; lean_object* x_13; +x_12 = lean_unbox(x_1); +lean_dec(x_1); +x_13 = l_Std_PersistentArray_forInAux___at_Lean_Server_FileWorker_handleDefinition___spec__5(x_12, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9, x_10, x_11); +lean_dec(x_10); +lean_dec(x_8); +lean_dec(x_7); +lean_dec(x_4); +lean_dec(x_3); +lean_dec(x_2); +return x_13; +} +} lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___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, lean_object* x_9, lean_object* x_10, lean_object* x_11, lean_object* x_12, lean_object* x_13) { _start: { @@ -17781,48 +17764,13 @@ lean_dec(x_2); return x_17; } } -lean_object* l_Std_PersistentArray_forInAux___at_Lean_Server_FileWorker_handleDefinition___spec__6___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, lean_object* x_9, lean_object* x_10, lean_object* x_11) { -_start: -{ -uint8_t x_12; lean_object* x_13; -x_12 = lean_unbox(x_1); -lean_dec(x_1); -x_13 = l_Std_PersistentArray_forInAux___at_Lean_Server_FileWorker_handleDefinition___spec__6(x_12, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9, x_10, x_11); -lean_dec(x_10); -lean_dec(x_8); -lean_dec(x_7); -lean_dec(x_4); -lean_dec(x_3); -lean_dec(x_2); -return x_13; -} -} -lean_object* l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__9___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, lean_object* x_9, lean_object* x_10, lean_object* x_11, lean_object* x_12, lean_object* x_13) { -_start: -{ -uint8_t x_14; size_t x_15; size_t x_16; lean_object* x_17; -x_14 = lean_unbox(x_1); -lean_dec(x_1); -x_15 = lean_unbox_usize(x_9); -lean_dec(x_9); -x_16 = lean_unbox_usize(x_10); -lean_dec(x_10); -x_17 = l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__9(x_14, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_15, x_16, x_11, x_12, x_13); -lean_dec(x_12); -lean_dec(x_8); -lean_dec(x_4); -lean_dec(x_3); -lean_dec(x_2); -return x_17; -} -} -lean_object* l_Std_PersistentArray_forIn___at_Lean_Server_FileWorker_handleDefinition___spec__5___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, lean_object* x_9, lean_object* x_10) { +lean_object* l_Std_PersistentArray_forIn___at_Lean_Server_FileWorker_handleDefinition___spec__4___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, lean_object* x_9, lean_object* x_10) { _start: { uint8_t x_11; lean_object* x_12; x_11 = lean_unbox(x_1); lean_dec(x_1); -x_12 = l_Std_PersistentArray_forIn___at_Lean_Server_FileWorker_handleDefinition___spec__5(x_11, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9, x_10); +x_12 = l_Std_PersistentArray_forIn___at_Lean_Server_FileWorker_handleDefinition___spec__4(x_11, x_2, x_3, x_4, x_5, x_6, x_7, x_8, x_9, x_10); lean_dec(x_9); lean_dec(x_7); lean_dec(x_4); @@ -39218,8 +39166,8 @@ l_Lean_Server_FileWorker_handleCompletion___closed__3 = _init_l_Lean_Server_File lean_mark_persistent(l_Lean_Server_FileWorker_handleCompletion___closed__3); l_Lean_Server_FileWorker_handleHover___closed__1 = _init_l_Lean_Server_FileWorker_handleHover___closed__1(); lean_mark_persistent(l_Lean_Server_FileWorker_handleHover___closed__1); -l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__2___closed__1 = _init_l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__2___closed__1(); -lean_mark_persistent(l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__8___lambda__2___closed__1); +l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__2___closed__1 = _init_l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__2___closed__1(); +lean_mark_persistent(l_Array_forInUnsafe_loop___at_Lean_Server_FileWorker_handleDefinition___spec__7___lambda__2___closed__1); l_Lean_Server_FileWorker_handleDefinition___closed__1 = _init_l_Lean_Server_FileWorker_handleDefinition___closed__1(); lean_mark_persistent(l_Lean_Server_FileWorker_handleDefinition___closed__1); l_Lean_Server_FileWorker_handleDefinition___closed__2 = _init_l_Lean_Server_FileWorker_handleDefinition___closed__2();