Lectures onType Theory
Chapter 140
Chapter 140Optional

Verified Metatheory and Realistic Trusted Kernels

Prerequisites. Direct starred prerequisites: Chapter 48 and chapter 126. No later core chapter depends on this route.

A verified bidirectional checker for a small calculus establishes that one algorithm decides one judgment. A production proof assistant is a different object. Its calculus has a universe hierarchy with constraints, mutual inductive families, a guard condition on fixed points, and cumulativity. Its checker must terminate on inputs whose reduction sequences no one has bounded. And the program that users run is not the verified function: it is the output of an extraction pass, compiled by an unverified toolchain, reading input through an unverified parser.

Between the two there are three distinct gaps, and it is worth separating them before any of them is closed. The calculus gap: the object the proof is about may not be the object the assistant implements. The termination gap: a checker that recurses on reduction needs a well-founded order, and no consistent theory proves its own normalization. The executable gap: even a verified function becomes a program only through extraction.

The test case is the formal PCUIC metatheory of Sozeau, Boulier, Forster, Tabareau, and Winterhalter. PCUIC is large enough to expose all three gaps while still providing exact mathematical statements for confluence, checking, and erasure. The claims below are about that stated calculus. They are not claims about every feature of any released proof assistant.

PCUIC and three grades of syntax

Definition 140.1 — Raw, scoped and well-formed syntax

The formalization distinguishes three grades of object.

Raw terms.

An inductive type of terms with de Bruijn indices, sorts, products, abstractions, applications, constants, inductive types, constructors, case analyses, projections and mutual fixed and cofixed points. Nothing is checked.

Scoped terms.

Raw terms all of whose variables are bound and all of whose constants, inductive types and constructors are declared in a given global environment.

Well-formed objects.

Scoped terms together with a derivation of the typing judgment Σ;Γt:T, in a global environment Σ that is itself well formed.

A theorem about one grade is not a theorem about another. In particular the checker of section 140.4 takes a raw term and either rejects it or returns a type together with a derivation.

Definition 140.2 — Universes

A universe is a nonempty list of levels with an added Boolean. A constraint is a triple of a level, a constraint type and a level. A valuation v assigns integers to levels, val(v,l) interprets a level, and v satisfies a constraint set when every constraint holds of the interpretation. A constraint set is consistent when some valuation satisfies it, and leq_universe(φ,u,u)iffevery valuation satisfying φ makes uu. Term comparison leq_term(φ,t,u) lifts equality and inequality of universes through the term structure.

The semantic definition of leq_universe quantifies over valuations, so it is not a decision procedure. The checker decides it by building a graph whose vertices are levels and whose edges are constraints, and testing acyclicity; the correctness of that test against definition 140.2 is a separate verified component.

Confluence

Definition 140.3 — Parallel reduction

Fix a well-formed global environment Σ. Write (Σ;Γ,t)(Δ,u) for the mutually defined parallel-reduction judgments on PCUIC contexts and terms. A derivation relates the source context Γ to the target context Δ while contracting any chosen family of redexes already present in t. The rules cover beta and zeta reduction, local and global definitions, case and projection reduction, mutual fixed points, mutual cofixed points, primitive values, and congruence under every term former. Write LC(Γ,t) for the side condition that the de Bruijn indices of Γ and t are in scope. Parallel reduction contains one-step reduction and is contained in its reflexive-transitive closure.

Theorem 140.4 — Parallel substitution; imported

Let Σ be well formed. Suppose (Σ;Γ,M)(Δ,M),(Σ;Γ,x:A,N)(Δ,x:A,N), and LC(Γ,M) and LC(Γ,x:A,N) hold. Then (Σ;Γ,N[M/x])(Δ,N[M/x]). The mutually proved strengthening replaces M by a simultaneous substitution, extends it under an arbitrary telescope, and reduces the source and target contexts in parallel.

Theorem 140.5 — Triangle property; imported

Let Σ be well formed. There are mutually defined complete-development functions ρΣ on contexts and ρΣ,Γ on terms. If LC(Γ,t) and (Σ;Γ,t)(Δ,u), then (Σ;Δ,u)(ρΣ(Γ),ρΣ,Γ(t)). In particular, reflexivity gives a reduction from t to its complete development.

The imported proofs are the mutually recursive PCUIC proofs, not the short paper sketch. Their supplied consequence is the common reduct in the next corollary.

Corollary 140.6 — One-step diamond

Let Σ be well formed and let LC(Γ,t). If (Σ;Γ,t)(Δ1,u1)and(Σ;Γ,t)(Δ2,u2), then, for i{1,2}, (Σ;Δi,ui)(ρΣ(Γ),ρΣ,Γ(t)).

Proof of Corollary 140.6 — One-step diamond

Proof. Apply theorem 140.5 to the two displayed derivations. Both conclusions have the same context ρΣ(Γ) and the same term ρΣ,Γ(t). ◻

Lemma 140.7 — Diamond closure

If a relation R has the diamond property, then its reflexive-transitive closure R is confluent.

Proof of Lemma 140.7 — Diamond closure

Proof. First prove the strip property aRb  aRcd. bRd  cRd by induction on the derivation of aRc. In the reflexive case, choose d=b. In the step case, write aRc1Rc. The diamond for aRb and aRc1 supplies e with bRe and c1Re. The induction hypothesis, applied to c1Re and c1Rc, supplies the required d.

Now induct on a derivation of aRb. The reflexive case chooses the endpoint of aRc. In the step case, write aRb1Rb. The strip property joins b1 to the endpoint of aRc at some d. Apply the induction hypothesis to b1Rb and b1Rd, then compose the path from c through d with the resulting path. The two composites have the required common endpoint. ◻

Corollary 140.8 — Confluence of parallel reduction

For fixed well-formed Σ, the reflexive-transitive closure of parallel reduction on locally scoped PCUIC configurations is confluent.

Proof of Corollary 140.8 — Confluence of parallel reduction

Proof. The one-step relation has the diamond property by corollary 140.6. Apply lemma 140.7. ◻

What is assumed, and why

Definition 140.9 — The oracles

Two syntactic conditions are treated as axioms rather than defined: fix_guard:mfixpoint termB,ind_guard:mutual_inductive_bodyB, together with the axiom that the fixed-point guard is stable under reduction: if fix_guard(mfix) and mfix reduces to mfix, then fix_guard(mfix).

Definition 140.10 — Normalization

The axiom normalisation states that for every context Γ and well-typed term t, t is accessible for the co-reduction relation cored — the converse of reduction — so that recursion on “reduces to” is well founded.

Remark 140.11 — Why these cannot be proved here

Strong normalization of PCUIC implies the consistency of PCUIC. A proof of it inside a theory at least as strong as PCUIC would contradict Gödel’s second incompleteness theorem. So definition 140.10 is not a gap that better technique closes: it is a boundary. The guard oracles of definition 140.9 are of a different kind — they could be defined, and the PCUIC development leaves them abstract deliberately, so that the checker’s correctness does not depend on any particular guard condition. The two are grouped as one assumption on the theory, which is what the phrase “trusted theory base” names.

Remark 140.12 — Two statements that remain conjectures

In the stated PCUIC theory, subject reduction and the existence of principal types are stated as conjectures, not theorems: if Σ;Γt:T and t reduces to u, then Σ;Γu:T;if Σ;Γu:A and Σ;Γu:B, then u has a type below both. A reader who assumes that a verified kernel comes with subject reduction is mistaken about this result. What is verified is that the checker, when it accepts, returns a derivation; that is a different statement and it does not require subject reduction.

Exercise 140.1

★★☆ Show that the soundness statement of theorem 140.14 does not use subject reduction, by exhibiting the dependency chain from its conclusion back to the definitions. Then name one property of a kernel that would need subject reduction, and say why the checker theorem does not claim it.

The checker

Definition 140.13 — Inference as a correct-by-construction function

Type inference is a function infer:Γtermtyping_result {AΣ;Γt:A}, where typing_result is an error monad with constructors Checked and TypeError, and squashes the derivation into a proposition so that extraction erases it. Checking is infer_cumul: infer the principal type of the subject, then check that it is convertible to or below the expected type.

Theorem 140.14 — Soundness of the checker

If the call infer Γ t returns Checked(A,p), then Σ;Γt:A.

Proof of Theorem 140.14 — Soundness of the checker

Proof. The conclusion is the type of the second component of the returned pair, so the statement holds because the function type-checks. This is the same move as proposition 134.2 of chapter 134: the obligation has been relocated into the construction of the function, where it is discharged by the proof obligations that the definition leaves open. ◻

Remark 140.15 — Completeness is not proved

The source metatheory does not prove that infer succeeds on every well-typed term. A checker that always returned TypeError would satisfy theorem 140.14. What rules that out in practice is that the checker is run; what would rule it out in principle is a completeness theorem, and there is none.

Construction 140.16 — Why the checker terminates

Reduction is implemented by a function reduce_stack that recurses on a term-with-stack. Its termination order is built in two layers. Let cored be the converse of reduction, and let a position be a list of choices with validpos checking that the position exists in the term; positions are ordered by posR. Set R Γ (u,π) (v,π)=dlexprod (cored Σ Γ) posRon the pair (zip(u,π), stack_pos(u,π)). That is: either the whole term strictly reduces, or it does not change and the focus moves to a strictly smaller position. By definition 140.10 the first component is well founded on well-typed terms, and positions in a fixed term are finite, so R is accessible.

The two layers are both necessary. Recursion on reduction alone cannot descend into a subterm without reducing; recursion on position alone cannot perform a reduction step. The lexicographic product is the smallest order that permits both, and the normalization axiom is used exactly once, to make its first component well founded.

Exercise 140.2

★★☆ Give a reduction sequence in which the stack reducer makes three consecutive recursive calls that do not reduce the whole term, and check that each call is smaller in the second component of the order R. Then give one call that does reduce the whole term, and say why its position may grow.

Erasure

Definition 140.17 — The target calculus

λ is untyped, with the constructors of PCUIC minus those that can only carry types, plus a constant for erased content. Its big-step evaluation is that of PCUIC with three amendments: an application whose function evaluates to evaluates to ; a case analysis on evaluates its single branch applied to as many times as that branch has arguments; and the fixed-point rule also applies when the principal argument evaluates to .

Definition 140.18 — The erasure function

E Σ Γ:termeterm is defined by first calling a decision procedure is_erasable, which returns either a proof that the term is erasable or a proof that it is not together with a proof that it is well typed; in the first case E returns , and otherwise it recurses structurally.

Proposition 140.19 — The function does not commute with evaluation

There are a well-typed term t and a value v with t evaluating to v for which E(t) does not evaluate to E(v).

Proof of Proposition 140.19 — The function does not commute with evaluation

Proof. Take t=(λZ:Type. (1,λx:Z.x)) Type, of type N×(TypeType). Its value is v=(1,λx:Type.x). Erasing t gives (λZ.(1,λx.x)) , whose value is (1,λx.x). Erasing v gives (1,), because λx:Type.x is a type former and is therefore erasable. The two values differ. ◻

The repair is not to change the function but to relate the two sides by something coarser.

Definition 140.20 — The erasure relation

Write Σ;Γtt for the erasure relation. It extends the graph of E with clauses that may preserve an erasable subterm. Case analysis is the exception. Matching on a proof of a non-informative proposition must erase the entire case, because an erased scrutinee does not determine a branch.

The proof needs three structural facts. They are stated together because the application case of the third uses the substitution clause of the first.

Lemma 140.21 — Structural erasure lemmas

Assume that Σ and Γ are well formed.

  1. If Σ;Γtt, then the judgment is stable under extension of Σ, weakening of Γ, and simultaneous substitution by pointwise-related substitutions σσ.

  2. Erasability is closed under application and evaluation. Moreover, if a lambda is erasable, then its body is erasable in the extended context.

  3. Suppose Σ;ΓmkApps(f,L):T and Σ;ΓmkApps(f,L)e. Exactly one of the following shapes is supplied by the last erasure rule:

    1. e=mkApps(f,L), with ff and pointwise LL;

    2. L=L1L2, the prefix mkApps(f,L1) is erasable, L2L2 pointwise, and e=mkApps(,L2).

Proof of Lemma 140.21 — Structural erasure lemmas

Proof. For the first clause, induct on the erasure derivation. Variables use the corresponding operation on indices. The lambda case lifts both substitutions under one binder. The let case lifts them under a definition and uses the induction hypotheses for the definiens and body. Application uses the two induction hypotheses. Constants use global weakening. Constructors erase their universe instances and are unchanged by term substitution. Informative case analysis and projection preserve their informative-inductive premise under global extension; apply the induction hypotheses to the scrutinee and, for a case, pointwise to the branches. For a fixed or cofixed block, lift the substitution through the complete mutual fixed-point context and apply the induction hypothesis to every body. The box clause follows because being a type or proof is preserved by weakening and typed substitution. These are all constructors of the erasure relation.

For the second clause, the application statement follows by inversion of typing: an erasable function has a sort or proposition as its result, and adding arguments does not introduce computational data. Lambda inversion is inversion of the same typing classification under its domain binder. For evaluation closure, induct on the evaluation derivation. Beta reduction uses lambda inversion and the substitution clause just proved. Let reduction uses substitution. Constant unfolding uses global weakening and the declaration’s typing derivation. Case and projection use the fact that eliminating a proof or type cannot produce informative data. Fixed- and cofixed-point unfolding use the pointwise hypotheses for the mutual block. Value rules preserve the given classification.

For the third clause, induct on L. At [], inversion gives either the relation for f or the box rule, which are the two alternatives with L1=[]. For L=L0u, invert the final erasure rule. An application rule exposes related prefixes and arguments; apply the induction hypothesis to the prefix and append the related argument to the appropriate suffix. A box rule makes the whole application erasable and gives the second alternative with L1=L and empty L2. No constructor, lambda, let, constant, case, projection, fixed-point, or cofixed-point erasure rule can conclude an application judgment. Hence the two alternatives are exhaustive. ◻

Theorem 140.22 — Erasure correctness

Let Σ be well formed and erase to Σ, let Σ;Γt:T erase to t, and let t evaluate to v. Then there is v with t evaluating to v and v erasing to v.

Proof of Theorem 140.22 — Erasure correctness

Proof. Induct on the derivation Σ;Γtv. Strengthen the induction hypothesis over the target environment Σ, the target term t, and the erasure derivation for t.

If t is erasable, lemma 140.21(2) makes v erasable. Choose v=. The target box evaluates to itself, and the box clause relates v to . This discharges every source rule whose erasure derivation ends in the box clause, including a case over a non-informative proposition.

For a lambda, constructor, fixed-point value, or cofixed-point value whose erasure is not a box, inversion gives the corresponding target constructor and related bodies. Choose that target value; its value rule is the required evaluation and the inverted erasure derivation relates the source value to it.

For a let, write the two source premises as t1v1 and t2[v1/x]v. Inversion of the non-box erasure gives t1t1 and t2t2. The first induction hypothesis produces t1v1 and v1v1. Typed substitution from lemma 140.21(1) gives t2[v1/x]t2[v1/x]. Apply the second induction hypothesis and finish with the target let rule.

For an application spine, use lemma 140.21(3). In its second alternative the target head is ; the amended target application rule evaluates the entire spine to , and evaluation closure makes the source result erasable. In the first alternative the head and arguments erase pointwise. Invert the source evaluation rule.

Beta.

The head and argument evaluate to λx.b and u, respectively, while b[u/x]v. The induction hypotheses give a target lambda and a related argument u. Lambda inversion gives a related body b, and substitution gives b[u/x]b[u/x]. Apply the body induction hypothesis, then the target beta rule.

Constant.

The environment-erasure premise supplies a target declaration with a related body. Global weakening transports that relation to the evaluation environment. Apply the induction hypothesis to the unfolded body and rebuild the target constant rule.

Fixed-point unfolding.

Inversion gives pointwise-related mutual bodies. Simultaneous substitution of the fixed-point block into its selected body is covered by lemma 140.21(1). Apply the induction hypothesis to the unfolded body and rebuild the target fixed-point rule. The cofixed-point head case uses the identical schema with the cofixed block and is triggered only by case or projection observation.

For an informative case, the scrutinee induction hypothesis produces the same constructor index in the target. Invert the pointwise branch relation, select the branch with that index, and use simultaneous substitution for its constructor arguments. The branch induction hypothesis gives its target value; the target case rule assembles the result. For a non-informative case, the box case above applies, and the special one-branch target rule supplies the required number of arguments. Projection is the one-field version: the scrutinee induction hypothesis produces a target constructor, inversion selects the projected argument, and the target projection rule returns its target value. A cofixed scrutinee is first unfolded by the cofixed-point schema from the application case.

The remaining evaluation rules are congruence instances for the same term constructors. Their erasure derivations expose exactly the premises already covered by the corresponding induction hypotheses, so rebuilding the matching target rule yields tv and the constructor erasure rule yields vv. The induction covers every value, beta, let, constant, application-spine, case, projection, fixed-point, and cofixed-point rule of the source evaluation relation, completing the proof. ◻

Proposition 140.23 — Where the function and the relation agree

Call a type first order when it is a non-propositional inductive type all of whose parameters and constructor arguments have first-order types. If Σ;Γt:T with T a fully applied first-order inductive type, t erases to t by the relation, and E(t) is defined, then t=E(t). Consequently, at a first-order type, if E(t)=t, t evaluates to v and E(v)=v, then t evaluates to v; and the value of E(f)E(L) is the erasure of the value of fL.

Remark 140.24

The two statements of proposition 140.23 are recorded in the source as non-mechanised observations. Theorem 140.22 has a formal proof; the specialization to first-order types, which is what a user of the extracted program actually relies on, does not. Reporting the two at the same level of confidence would conflate a proved relation theorem with an informal functional specialization.

Exercise 140.3

★★☆ Explain why the case-analysis clause of definition 140.20 cannot be made permissive. Exhibit a term whose erasure would otherwise evaluate to two different values, and then say what changes when the proposition being matched is informative with at most one branch.

Extraction and execution

The verified checker becomes a program by extraction to a functional language. Three facts about that step belong in the audit.

First, the extraction pass is not verified, and on this development it initially produced an ill-typed program. The cause was a function whose result type’s arity depended on a Boolean value; the workaround restructures the conversion algorithm’s return type from if b then B{a:A & C} else {a:A & C}to(if b then B else unit){a:A & if b then Ca else C}, so that the structure of the type no longer depends on b. That a verified component had to be rewritten to survive an unverified pass is itself the argument for verifying the pass.

Second, the extracted checker runs. It was tested on proof terms from a homotopy-type-theory library and is about one order of magnitude slower than the assistant’s own kernel, an overhead attributed to representing global environments as association lists indexed by character lists.

Third, it cannot check its own formalization: modules and template polymorphism are outside the formalized calculus. There is therefore no bootstrapping claim.

The trust audit

Definition 140.25 — What remains trusted

To believe that a term accepted by the extracted checker is well typed in PCUIC, one trusts:

  1. Axioms. The guard oracles and their stability under reduction (definition 140.9); the normalization axiom (definition 140.10).

  2. Unproved statements. Subject reduction and principality, which are conjectures (remark 140.12); completeness of inference, which is not proved (remark 140.15); the first-order specialization of erasure, which is non-mechanised (remark 140.24).

  3. The specification. That the formalized PCUIC is the calculus the assistant implements. Modules and template polymorphism are not formalized, so for programs using them the specification is silent.

  4. Generated and extracted code. The extraction pass, the compiler for the target language, its runtime, and the operating system and hardware.

  5. The boundary programs. The parser that turns input into raw terms, the serializer that writes results, any plugin, and — when the checker is invoked from inside the assistant — the host kernel that ran the verification in the first place.

Remark 140.26 — Two non-transfers

An initiality theorem — that the syntax of a type theory is the initial object of a category of models — does not verify a checker: it says nothing about any algorithm. And an internally verified checker does not remove its host chain from the trusted base: the verification was carried out by the host, so trusting its result already presupposes the host, and only a bootstrapping theorem — the checker checking its own formalization — would change that. Section 140.6 records why the second is not available here.

Remark 140.27 — Non-transfer against the small kernel

The small bidirectional kernel of chapter 48 and the PCUIC checker are not comparable point by point, and three differences must be kept in view. The small kernel’s calculus is a fragment with no inductive families, no universe constraints and no guard condition, so its metatheorems are about a different object. Its termination argument is available because its calculus normalizes provably in the ambient metatheory, whereas construction 140.16 needs an axiom. And its checker is exhibited as a program in the book’s own notation, not extracted, so it has no extraction boundary — and correspondingly it makes no claim about any deployed binary. No theorem transfers in either direction.

Four kinds of mechanized evidence

The audit above is about one formal calculus and its checker. Four other developments are worth placing beside it, because each supplies a different kind of evidence and none is a theorem about PCUIC.

A controlled binding representation.

A development that fixes one representation of binding and proves the invariants that representation must satisfy supplies representation evidence: that the syntax being reasoned about is the syntax intended. It says nothing about any algorithm.

A benchmark for logical relations.

A challenge problem whose solutions are compared across assistants supplies proof-technique evidence: that a particular metatheoretic argument is carried out in full. Its subject is a small calculus, chosen so that the technique is visible.

Functional big-step semantics.

A semantics written as a fuel-indexed interpreter, proved adequate against a relational semantics, supplies executable-semantics evidence: that the definition one runs and the definition one reasons about agree. Adequacy is the theorem; the fuel is the price.

Compiler verification.

An end-to-end development for a lazy language whose theorem relates source observations to target observations supplies compiler evidence, of the kind proved in chapter 134. Its trusted base has the shape of definition 140.25 with different contents.

Convention 140.28 — How a comparison must be stated

Each comparison names its calculus, its hypotheses, its theorem signature, and whether the theorem concerns an internal definition or an extracted program. A result about one calculus does not transfer to PCUIC merely because their syntax resembles each other, and theorem names do not establish comparable conclusions.

Limits and seminar

Sources. The source is Sozeau, Boulier, Forster, Tabareau, and Winterhalter’s PCUIC development [SBF^+20]. The definitions used here are definition 140.1, definition 140.2, definition 140.3 together with definition 140.9, definition 140.10, definition 140.13 and definition 140.17, definition 140.18, definition 140.20. Theorem 140.4, Theorem 140.5 import the full PCUIC proof, not the paper’s two-page account. The substitution infrastructure occupies the span from pred1_subst through substitution0_pred1 in the formal module PCUICParallelReduction. The module PCUICParallelReductionConfluence proves triangle_gen by the mutual context-and-term induction and derives triangle and pred1_diamond. Together these two formal proofs occupy more than six thousand source lines, well over ten rendered pages. The paper prints their signatures on physical PDF pp. 13–14. The erasure rules and theorem are printed on physical PDF pp. 23–25; because that source span is shorter than ten pages, lemma 140.21, theorem 140.22 incorporate the proof in the chapter. Corollary 140.8 and proposition 140.19 are also proved locally, the second from the counterexample the source gives, and proposition 140.23 is recorded as non-mechanised, per remark 140.24.

Six boundaries. The performance observations in section 140.6 are source observations, not consequences of the checker-soundness theorem. Subject reduction and principality are conjectures in the source theory, not theorems. Completeness of inference is unproved. The first-order erasure corollaries are non-mechanised. Modules and template polymorphism are unformalized, so the checker cannot check its own development and there is no bootstrapping result. And every claim above is about the calculus PCUIC as formalized; whether the released assistant implements exactly that calculus is a question about the assistant, not a theorem of the formal PCUIC metatheory.

[4]

Suggested first pass.

None of these problems is a prerequisite for a later chapter. Begin with exercise 140.4, then complete exercise 140.7.

Exercise 140.4

★★☆ Take a specific claim — “this proof term is well typed in PCUIC” — and write the full chain of things trusted, following definition 140.25, marking each link as an axiom, an unproved statement, a specification assumption, or an unverified program. Then delete the extraction step by supposing the checker is run inside the assistant, and say exactly which links disappear and which are added.

Exercise 140.5

★★★ Extend proposition 140.19 to a term of type N×(NN), or show that no such counterexample exists at that type. Then state precisely the class of types at which the erasure function commutes with evaluation, and compare it with the first-order types of proposition 140.23.

Exercise 140.6

★★★ Replace the lexicographic order of construction 140.16 by recursion on the size of the term. Exhibit a reduction that increases the size, conclude that the replacement fails, and then say which of the two components of R the size order was trying to replace.

Exercise 140.7 — Practical: a declaration and erasure trace

★★★ Practical project.mrq-trace-checker Complete project mrq-trace-checker. For a finite fragment of the kernel’s data — a global environment of constant and inductive declarations, a universe constraint set, and a small term language — implement (i) the consistency test of definition 140.2 as an acyclicity check on the constraint graph, (ii) a bidirectional checker that returns either a type or a named error, (iii) the erasability test and the erasure function of definition 140.18, and (iv) evaluation for both the source and λ. The invariant the implementation must maintain is that whenever the checker accepts a term at a first-order type, the erasure of its value equals the value of its erasure, which is proposition 140.23 on the implemented fragment. The named cases print

consistent-graph: accepted
cyclic-graph: rejected
undeclared-constant: rejected
erase-first-order: agree
erase-higher-order: differ

The checker is independent evidence for the fragment; it does not implement PCUIC, does not decide the guard condition, assumes nothing about normalization because its fragment is finite, and — by remark 140.24 — its last two cases exercise a non-mechanised observation rather than theorem 140.22.

Search the book

Type to search the local edition.