Equations
- SecondOrder.instReprKind = { reprPrec := SecondOrder.reprKind✝ }
Equations
- SecondOrder.instDecidableEqKind x y = if h : x.toCtorIdx = y.toCtorIdx then isTrue ⋯ else isFalse ⋯
Equations
- SecondOrder.«term∗» = Lean.ParserDescr.node `SecondOrder.term∗ 1024 (Lean.ParserDescr.symbol " ∗ ")
Instances For
Equations
- SecondOrder.instToStringKind = { toString := fun (k : SecondOrder.Kind) => match k with | ∗ => "∗" }
- var: Name → SecondOrder.Typ
- arrow: SecondOrder.Typ → SecondOrder.Typ → SecondOrder.Typ
- pi: Name → SecondOrder.Kind → SecondOrder.Typ → SecondOrder.Typ
Instances For
Equations
- SecondOrder.instReprTyp = { reprPrec := SecondOrder.reprTyp✝ }
Equations
- (SecondOrder.Typ.var a).toString = a
- (a ⇒ a_1).toString = toString "(" ++ toString a.toString ++ toString " → " ++ toString a_1.toString ++ toString ")"
- (SecondOrder.Typ.pi a a_1 a_2).toString = toString "(Π " ++ toString a ++ toString " : " ++ toString a_1 ++ toString ". " ++ toString a_2.toString ++ toString ")"
Instances For
Equations
- SecondOrder.Typ.instToString = { toString := SecondOrder.Typ.toString }
Equations
- SecondOrder.Typ.instCoeName = { coe := SecondOrder.Typ.var }
Equations
- SecondOrder.Typ.«term_⇒_» = Lean.ParserDescr.trailingNode `SecondOrder.Typ.term_⇒_ 20 21 (Lean.ParserDescr.binary `andthen (Lean.ParserDescr.symbol " ⇒ ") (Lean.ParserDescr.cat `term 20))
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- (SecondOrder.Typ.var a).FTV = {a}
- (a ⇒ a_1).FTV = a.FTV ∪ a_1.FTV
- (SecondOrder.Typ.pi a a_1 a_2).FTV = a_2.FTV \ {a}
Instances For
Equations
- (SecondOrder.Typ.var a).subst α B = if α = a then B else SecondOrder.Typ.var a
- (a ⇒ a_1).subst α B = (a.subst α B ⇒ a_1.subst α B)
- (SecondOrder.Typ.pi a a_1 a_2).subst α B = if α = a ∨ a ∈ B.FTV then SecondOrder.Typ.pi a a_1 a_2 else SecondOrder.Typ.pi a a_1 (a_2.subst α B)
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
- var: Name → SecondOrder.Term
- app: SecondOrder.Term → SecondOrder.Term → SecondOrder.Term
- tapp: SecondOrder.Term → SecondOrder.Typ → SecondOrder.Term
- abs: Name → SecondOrder.Typ → SecondOrder.Term → SecondOrder.Term
- tabs: Name → SecondOrder.Kind → SecondOrder.Term → SecondOrder.Term
Instances For
Equations
- SecondOrder.instReprTerm = { reprPrec := SecondOrder.reprTerm✝ }
Equations
- (SecondOrder.Term.var a).toString = a
- (a ∙ a_1).toString = toString "(" ++ toString a.toString ++ toString " " ++ toString a_1.toString ++ toString ")"
- (a ∙ₜ a_1).toString = toString "(" ++ toString a.toString ++ toString " " ++ toString a_1.toString ++ toString ")"
- (SecondOrder.Term.abs a a_1 a_2).toString = toString "(λ" ++ toString a ++ toString " : " ++ toString a_1 ++ toString ". " ++ toString a_2.toString ++ toString ")"
- (SecondOrder.Term.tabs a a_1 a_2).toString = toString "(Λ" ++ toString a ++ toString " : " ++ toString a_1 ++ toString ". " ++ toString a_2.toString ++ toString ")"
Instances For
Equations
- SecondOrder.Term.instToString = { toString := SecondOrder.Term.toString }
Equations
- SecondOrder.Term.instCoeName = { coe := SecondOrder.Term.var }
Equations
- SecondOrder.Term.«term_∙_» = Lean.ParserDescr.trailingNode `SecondOrder.Term.term_∙_ 100 100 (Lean.ParserDescr.binary `andthen (Lean.ParserDescr.symbol " ∙ ") (Lean.ParserDescr.cat `term 101))
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
- type: Name × SecondOrder.Typ → SecondOrder.Declaration
- kind: Name × SecondOrder.Kind → SecondOrder.Declaration
Instances For
Equations
- SecondOrder.instReprDeclaration = { reprPrec := SecondOrder.reprDeclaration✝ }
@[reducible, inline]
Instances For
- var: ∀ {Γ : SecondOrder.Context} {x : Name}, Γ ⊢ₖ SecondOrder.Typ.var x : ∗
- arrow: ∀ {Γ : SecondOrder.Context} {σ τ : SecondOrder.Typ}, (Γ ⊢ₖ σ : ∗ ) → (Γ ⊢ₖ τ : ∗ ) → Γ ⊢ₖ σ ⇒ τ : ∗
Instances For
- var: ∀ {Γ : SecondOrder.Context} {x : Name} {σ : SecondOrder.Typ}, SecondOrder.Declaration.type (x, σ) ∈ Γ → Γ ⊢ SecondOrder.Term.var x : σ
- app: ∀ {Γ : SecondOrder.Context} {M N : SecondOrder.Term} {σ τ : SecondOrder.Typ}, (Γ ⊢ M : σ ⇒ τ) → (Γ ⊢ N : σ) → Γ ⊢ M ∙ N : τ
- abs: ∀ {Γ : SecondOrder.Context} {x : Name} {M : SecondOrder.Term} {σ τ : SecondOrder.Typ}, (insert (SecondOrder.Declaration.type (x, σ)) Γ ⊢ M : τ) → Γ ⊢ SecondOrder.Term.abs x σ M : σ ⇒ τ
- tabs: ∀ {Γ : SecondOrder.Context} {α : Name} {M : SecondOrder.Term} {A : SecondOrder.Typ}, (insert (SecondOrder.Declaration.kind (α, ∗ )) Γ ⊢ M : A) → Γ ⊢ SecondOrder.Term.tabs α ∗ M : SecondOrder.Typ.pi α ∗ A
- tapp: ∀ {Γ : SecondOrder.Context} {α : Name} {M : SecondOrder.Term} {A B : SecondOrder.Typ}, (Γ ⊢ M : SecondOrder.Typ.pi α ∗ A) → (Γ ⊢ₖ B : ∗ ) → Γ ⊢ M ∙ₜ B : A.subst α B
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Instances For
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- SecondOrder.Combinators.id = SecondOrder.Term.tabs "α" ∗ (SecondOrder.Term.abs "x" (SecondOrder.Typ.var "α") (SecondOrder.Term.var "x"))
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.