Skip to content

Preview: the arena after the kernel renovation - #391

Draft
nomeata wants to merge 59 commits into
masterfrom
renovation-tests
Draft

nomeata wants to merge 59 commits into
masterfrom
renovation-tests

Conversation

@nomeata

@nomeata nomeata commented Nov 22, 2026 •

Copy link
Copy Markdown
Collaborator

This is the arena as it would look after the kernel logic renovation (lean4#14977). It is not meant to be merged as is; it is deployed as a preview at https://leanprover.github.io/lean-kernel-arena-beta/ (from leanprover/lean-kernel-arena-beta, branch renovation), and this PR lists what changes.

All tests are exported with the toolchain of lean4#16595 (pr-release-16595-a8ad4db), which adds the per-inductive flags isImpredicative, isK, hasProjections, hasEta and hasLargeElim to the kernel and to the export format (and drops isReflexive). The official checker is that toolchain's leanchecker. It gives every test its expected verdict, except the tests of changes of the renovation that the toolchain does not have yet (complete level comparison and lean4#15372), which are meant to show up red until it does. No checker declines the new tests.

Tests whose verdict changed

  • tutorial/projProp1, tutorial/projProp3: good → bad. PropStructure has data fields, so it is impredicative, and impredicative types have no projections.
  • corner-cases/proj-maybe-prop, corner-cases/proj-maybe-prop-past: either → accept, moved into renovation/ (projMaybeProp, projMaybePropPast). A structure in Sort u may have projections by the flag rules alone; whether it may be a proposition no longer matters, and with eta its recursor eliminates into every universe, so lean4#7637 is gone.
  • corner-cases/large-elim-maybe-prop: either → accept, moved into renovation/ (maybePropBoxGet, with a bad twin MaybePropBoxNoEta). Such a type may have large elimination through hasEta.
  • corner-cases/eta-struct-major-and, corner-cases/eta-struct-major-and-no-whnf: either → accept, moved into renovation/ (andMajorEta, andMajorNoWhnf). Structure eta applies to the major premise of a recursor of every type with hasEta, propositions like And included, before the major is reduced (lean4#15371).
  • corner-cases/imax-nested-absorption, corner-cases/imax-right-successor: either → accept, moved into renovation/ (levelImax*), with more shapes of level relations that hold for every assignment: levels are compared completely.
  • corner-cases/eta-unit-like-struct, -pi, -proof-field, -nested: either → accept, moved into renovation/ (unitLike*): eta for unit-like types (lean4#15372).
  • corner-cases/eta-ctor, corner-cases/eta-rec-struct, corner-cases/eta-rule-k: either → accept, moved into renovation/ (etaCtor, etaRecStruct, etaRuleK): eta for partial applications of constructors and recursors (lean4#15373, lean4#15374).
  • corner-cases/alg-conv-trans-quot-left, -left-def, corner-cases/alg-conv-trans-quot: either → reject, corner-cases/alg-conv-trans-quot-right: either → accept, moved into renovation/ (quotLiftNoProofIrrel, quotLiftDefNoProofIrrel, quotLiftTrans, quotLiftMk): quotients of propositions are types, so proof irrelevance does not apply to their elements (lean4#15023).
  • other/sparse-name-index, other/level-index-out-of-order: accept → either, moved to corner-cases/. The export format specifies that references are assigned consecutively and in order; checkers may be permissive, but need not support such files.

Tests whose meaning changed (same verdict)

  • tutorial/sortElimPropRec: now asserts that a predicate whose constructor carries data eliminates into Prop only.
  • bugs/large-elim-param, bugs/large-elim-prop-bool: the forged large recursor of a type that may be (or is) a proposition with two constructors is now exported with hasLargeElim, a flag a checker must reject.
  • bugs/proj-of-imax-prop: ImaxProp : Sort (imax 1 0) is impredicative, so its projection is rejected for lack of projections.
  • tutorial/reflOccInIndex: was rejected for unrelated reasons (a wrong de Bruijn index, a field too big for I : Type → Type, a wrong field count); now I : Prop → Prop, rejected for the recursive occurrence in index position only.

Tests dropped

No longer expressible, as Acc (lean4#13851), and propositions whose proofs carry data, no longer have large elimination:

  • corner-cases/alg-conv-trans-acc, -left, -right, corner-cases/subject-reduction-redex, -reduct: eliminate Acc into Bool.
  • corner-cases/eta-struct-major-no-whnf: eliminates Acc into Nat × Nat.
  • bugs/proj-of-subst-prop, bugs/rec-of-subst-prop, bugs/rec-missing-ih, bugs/proj-of-stuck-prop: rely on Acc eliminating into Bool (the latter also on projections out of propositions).
  • bugs/rec-rule-proof-irrel, -nested, bugs/rec-type-proof-irrel: eliminate Box : Bool → Prop, whose field occurs in its index, into Bool.
  • tutorial/ruleKAcc, tutorial/accRecReduction, tutorial/accRecNoEta: eliminate Acc into Bool.

Not ported:

  • bugs/nested-unused-param: relies on a hash collision of Exprs that no longer collides with the newer Lean; it would need a new collision.

Dropped from the preview for speed only, as they are exported with their own toolchains (to come back): mathlib, cslib, navier-stokes-euler, cedar, reachability, con-leche.

New tests

renovation/ (138 tests, generated from renovation/Renovation.lean, each checked by the kernel of lean4#16595 when written out, except those of changes it does not have yet): one or more good and bad tests per flag and condition, mutual and nested blocks, recursor shape (motive universe and its name, rules, k), projections, structure and unit-like eta, the tests moved from corner-cases/ above, level relations that hold (good) or do not (bad) for every assignment, and tests for Quot living in Sort (max 1 u) (lean4#15023).

Other changes

  • Only checkers that support the inductive flags are kept: official (the leanchecker of the PR release), con-leche (con-leche#24) and con-ron (both on their renovation branches), and gruszka (partly, since 0.2.0). The others come back once they support the flags.
  • The hand-written inductive types of the tutorial, the single-file tests and the static exports carry the flags they would have were it not for the defect a test is about; recursors without large elimination have no rules.
  • Test descriptions no longer state what checkers do in the present tense.
  • lka.py: declining a test with subtests declines all of them; declines may contain glob patterns.
  • Preview only: deploys from renovation, no rounds, titles say "Preview".

Coverage of the renovation

Change Status in the toolchain Tests
lean4#16595 flags for inductives, no rules for small recursors the toolchain renovation/ (all but the Quot tests), bugs/large-elim-param, bugs/large-elim-prop-bool, bugs/nat-rec-k-lie, bugs/rec-k-lie, bugs/proj-of-imax-prop, tutorial/projProp*
lean4#13851 no large elimination of recursive predicates (Acc) included renovation/LAcc, SAcc, LRec, tutorial/sortElimPropRec
Sort-polymorphic structures with large elimination (lean4#7637) part of #16595 renovation/MaybeProp, projMaybeProp*, MaybePropBox, maybePropBoxGet, MaybePropBoxNoEta, LPolyUnit
lean4#15371 eta-expand recursor majors of subsingleton structures included renovation/andMajorEta, andMajorNoWhnf
lean4#15372 extended unit-like eta reverted on master (lean4#16443), not in the toolchain renovation/unitLike* (ahead)
lean4#15373 eta-expand partial constructor applications included renovation/etaCtor, bugs/eta-ctor-alias
lean4#15374 eta-expand partial recursor applications included renovation/etaRecStruct, etaRuleK, etaRecNoEta
lean4#15023 quotients of propositions in Type open, but in the toolchain renovation/quotOfPropIsType, quotOfPropNoProofIrrel, quotLiftMk, quotLiftNoProofIrrel, quotLiftDefNoProofIrrel, quotLiftTrans
lean4#15103 do not reduce proofs in is_def_eq_core included only performance tests: perf/irrelevance-before-evaluation, perf/irrelevance-refutes
lean4#14896 theorems are opaque included none (hardly observable, as proofs are irrelevant)
Complete level comparison no PR yet renovation/levelImax* (good ones ahead), levelMaxImaxNotAbsorb, levelImaxNotGeLeft

Open ends: the remaining corner cases (let-value-type-mismatch, nested-*, positivity-whnf, proof-param-swap, vanishing-occurrence, sparse-name-index, level-index-out-of-order) are about checker policy, which no change of the renovation decides. All exports say export format version 3.2.0.

🤖 Generated with Claude Code

https://claude.ai/code/session_01WD3k8heqxUkfnTTjyEie76

nomeata and others added 14 commits November 22, 2026 18:27
This adds 91 small tests (49 good, 42 bad) for the per-inductive feature
flags `isImpredicative`, `isK`, `hasProjections`, `hasEta` and
`hasLargeElim` that lean4#16595 adds to the kernel and to the export format
(3.2.0), one per flag and condition, including mutual and nested blocks,
recursor shape (motive universe and its name, rules, `k`), projections, and
structure and unit-like eta.

Like the tutorial tests, they are generated from a Lean project
(`renovation/`), pinned to the PR release of lean4#16595, and written out
with the exporter that ships with it. Each inductive type is elaborated as
usual and then sent to the kernel with explicit flags; bad blocks are built
from a well-formed variant with the flags replaced. The generator checks that
the kernel accepts every good test and rejects every bad one.

All checkers decline the tests for now, so they can opt in. To support that,
declining a `multiple` test now declines all its subtests, also when they
were not built (`build-test --skip-declined-by`); the site then shows each
subtest as declined.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
The official checker from the PR release of lean4#16595 (at 53e1623), so
that one checker handles the renovation tests. It declines all other tests,
for which `declines` may now contain glob patterns such as `bugs/*`. That
release predates the final version of the PR, so it gets 17 of the 91 tests
wrong.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…n tests

leanprover/con-leche#24 reads the inductive flags of export format 3.2.0.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
This branch is the main branch of leanprover/lean-kernel-arena-beta, a
preview of the arena with the renovation tests (lean4#14977, lean4#16595):

* No checker declines the renovation tests, so those that do not handle
  them show it.
* The site's title says it is a preview, and the front page links to the
  actual arena.
* Builds of the branch `renovation` deploy the site, and reuse the results
  of the latest one.
* There are no rounds: release-round.yml is gone.
* Links to the sources point to this repository.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
mathlib, cslib, navier-stokes-euler, cedar, reachability and the con-leche
test corpus are exported with the toolchains of their own repositories, so
they do not exercise the inductive flags, and they make every build of the
preview take hours. init, init-prelude and std stay. Without mathlib, the
speed comparisons on the preview are vacuous. The declines of the dropped
tests stay, as the tests are to come back.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…3431e

The PR release of lean4#16595 at its head generates no reduction rules for
recursors without large elimination, and checks that only the first type of
a mutual block is marked `isK`, so the workarounds for the older release are
gone. The exports are unchanged (but for the metadata), and its leanchecker
gets all 91 tests right. Also bumps con-ron to the head of its renovation
branch.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
So that the tutorial tests are exported with the inductive flags, too. The
single-file tests, init and std (tests/) and the tutorial page renderer
(test-printer) stay on v4.36.0, as many of the single-file tests would need
porting to the new rules.

* Constants that bypass the kernel go into the local map, as imported
  constants are no longer kept in a map that can be inserted into.
* The hand-written inductive types get flags: all off for the bad ones, the
  natural ones for the good ones.
* `sortElimPropRec` now asserts that such a predicate eliminates into Prop
  only, and the tests about `Acc` eliminating into Sort are gone.
* `projProp1` and `projProp3` are now bad: `PropStructure` is impredicative,
  so it has no projections.

All 138 tests get the expected verdict from the PR release's leanchecker.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
bugs/nested-unused-param, bugs/proj-of-stuck-prop and
corner-cases/nested-nonuniform-param are modules of the tutorial project,
which is now on the PR release of lean4#16595.

* corner-cases/nested-nonuniform-param only needed flags for its
  hand-written inductive type; the kernel of the PR release still rejects it
  for its non-uniform parameter.
* bugs/nested-unused-param relies on a hash collision of the older Lean
  version, and bugs/proj-of-stuck-prop on `Acc` eliminating into `Bool` and
  on projections out of propositions, which the new rules take away. They are
  dropped from the preview.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
The PR no longer has the `isReflexive` flag, so the tutorial's hand-written
inductive types lose it, and the test printer (still on v4.36.0) takes it to
be off when an export lacks it. The renovation tests themselves move along in
the next commit.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WD3k8heqxUkfnTTjyEie76
lean4#15023 makes `Quot` live in `Sort (max 1 u)` rather than `Sort u`, so
that quotients of propositions are types. Two hand-crafted tests check that a
checker has that `Quot`: a quotient of `True` is a `Type` (good), and two of
its elements are not equal by proof irrelevance (bad).

lean4#15023 is not in the toolchain of lean4#16595, so the generator replaces
the type of `Quot` itself, bypassing the kernel. For the exporter to write out
the replaced `Quot` rather than the imported one, it is now given an
environment with just the constants it writes out, taken from the kernel
environment; the other exports are unchanged. Also bumps the renovation
project to the release of lean4#16595 at 55bd690 (no `isReflexive`); the
release's leanchecker gets all but the good quotient test right.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WD3k8heqxUkfnTTjyEie76
@nomeata

nomeata commented Nov 24, 2026

Copy link
Copy Markdown
Collaborator Author

@nomeata nomeata closed this Nov 24, 2026
nomeata and others added 9 commits November 24, 2026 11:37
So that init, init-prelude, std and the single-file tests are exported with
the inductive flags, too.

* Tests that forge a constant now replace it for the kernel and for the
  elaborator alike, as imported constants are no longer kept in a map that
  can be inserted into (ctor-num-fields, large-elim-prop-bool,
  nested-rec-rule-nfields, rec-k-lie, rec-rule-wrong-arg).
* The hand-written inductive types get the flags the elaborator would choose
  (proj-of-imax-prop, proj-maybe-prop, nested-redex-aux,
  vanishing-occurrence).
* Tests that need large elimination of `Acc`, or of a proposition whose
  proofs carry data (`Box`), are gone, as that is no longer expressible:
  alg-conv-trans-acc{,-left,-right}, subject-reduction-{redex,reduct},
  eta-struct-major-no-whnf, proj-of-subst-prop, rec-of-subst-prop,
  rec-rule-proof-irrel{,-nested} and rec-type-proof-irrel.

The PR release's leanchecker gives every built test its expected verdict.
The hand-written static exports are not ported yet; of those,
corner-cases/proof-param-ok, lacking the flags, fails to parse.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WD3k8heqxUkfnTTjyEie76
With the inductive flags (lean4#16595), whether `MaybeProp` has projections
is its declared `hasProjections`, which it may have, and whether it might be
a proposition no longer matters. With `hasEta`, its recursor also eliminates
into every universe, so the mismatch of lean4#7637 that made their outcome
open is gone.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WD3k8heqxUkfnTTjyEie76
All tests of the preview are exported with the inductive flags now, so the
official checker is the one of the PR release of lean4#16595, on all of them.
official-renovated, which ran it on the renovation tests only, is gone, and
official-nightly, which predates the flags, is disabled.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WD3k8heqxUkfnTTjyEie76
Each gets the flags it would have were it not for the defect the test is
about, rather than all of them off, so that the export is what a kernel
lacking the check would have written.

reflOccInIndex was rejected for unrelated reasons: its index referred to the
`Nat` argument rather than to `α`, `α : Type` was too big a field for
`I : Type → Type`, and it had two fields, not one. It is now
`I : Prop → Prop` (impredicative, for its field `α : Prop`), and rejected for
the recursive occurrence in index position only.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WD3k8heqxUkfnTTjyEie76
The inductive types of the static exports now carry the five flags of
lean4#16595 (and no `isReflexive`): those of the toolchain for the core types,
and for the tests' own types those they would have were it not for the defect
the test is about. In bugs/large-elim-param, `MyBool : Sort u` keeps
`hasLargeElim`, which is now the claim to be rejected. Recursors' `k` follows
`isK` (except for the forged `k` in bugs/nat-rec-k-lie), and a recursor
without large elimination has no rules (other/inductive-undeclared-universe).

bugs/rec-missing-ih is gone: it relies on `Acc` eliminating into `Bool`.

With the PR release's leanchecker, every one of them gets its expected
verdict, for the reason it is about.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WD3k8heqxUkfnTTjyEie76
With the inductive flags of lean4#16595, these are no longer open:

* proj-maybe-prop{,-past}: a structure in `Sort u` may have projections
  (and eta and large elimination) by the rules for the flags alone; whether
  it may be a proposition no longer matters.
* large-elim-maybe-prop: such a type may have large elimination through
  `hasEta`; a twin without `hasEta` must be rejected.
* eta-struct-major-and{,-no-whnf}: structure eta applies to the major premise
  of a recursor of every type with `hasEta`, including `And`, before reducing
  the major.

They are now generated renovation tests, checked by the kernel of the PR
release when they are written out. The other corner cases are about changes
outside the flags and stay.

The exporter of the renovation tests now also follows the values of
theorems, which none of them needed before.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WD3k8heqxUkfnTTjyEie76
Descriptions now say what a test exercises and what the correct outcome
is, rather than what a particular checker (mostly the official kernel) does
or does not do in the present tense: such statements are either generic
("a checker that …"), history in the past tense, or references to proposals
for the official kernel.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WD3k8heqxUkfnTTjyEie76
The export format specifies that the internalization-table references are
assigned consecutively and in order. Checkers may be permissive about it,
but need not support files that are not, so sparse-name-index and
level-index-out-of-order move from other/ to corner-cases/ with outcome
either.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WD3k8heqxUkfnTTjyEie76
@nomeata nomeata reopened this Nov 24, 2026
@nomeata nomeata changed the title Add renovation/ tests for the inductive flags of lean4#16595 Preview: the arena after the kernel renovation Nov 24, 2026
@nomeata
nomeata marked this pull request as draft November 24, 2026 12:04
nomeata and others added 2 commits November 24, 2026 14:55
The heads of their renovation branches support `Quot` living in
`Sort (max 1 u)` (lean4#15023), as in the renovation tests.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WD3k8heqxUkfnTTjyEie76
Pinned to released versions: gruszka 0.2.0 (tag v0.2.0), susz 0.4.0.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
nomeata and others added 30 commits November 25, 2026 15:54
… tests

The arena should show what still needs work, so the corner cases that a
change of the renovation (lean4#14977) decides are now definite tests:

* Complete level comparison: the imax corner cases, and more shapes of
  level equations and inequalities that hold for every assignment but that
  the kernel of lean4#16595 does not establish (an imax with a nonzero right
  operand, absorption, distributivity over max, nesting, and imax u v <=
  max u v), with bad tests for false ones that look alike.
* Eta for unit-like types (lean4#15372) and for partial applications of
  constructors and recursors (lean4#15373, lean4#15374): eta-unit-like-*,
  eta-ctor, eta-rec-struct and eta-rule-k, now accept tests.
* Quotients of propositions being types (lean4#15023): alg-conv-trans-quot*,
  where conversion now does not hold (left, left', trans: reject) or holds by
  the computation rule (right: accept).

Tests of changes that the toolchain does not have yet are added without the
kernel checking them, and the generator warns once it accepts them. The
corner cases that remain are about checker policy.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
In the preview repository, deploy-pages repeatedly looked the artifact up
before the run's list of artifacts had it, and failed with "No artifacts
named github-pages-1 were found". Poll the list for up to five minutes
first.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Each eta rule of the renovation now also has a test of where it must not
apply: no structure eta on the major premise of a recursor (lean4#15371),
no function eta for a partially applied constructor (lean4#15373) or a
recursor missing its major premise (lean4#15374) of a structure without
`hasEta`; and no unit-like eta (lean4#15372) for a structure with a `Bool`
field, a function type into `Bool`, or a structure without `hasEta` whose
fields are unit-like. Also a good test of structure eta on the major premise
for a structure in `Type`.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
letTypeDep, letRed, proofIrrelevanceUnderBinder and four hand-written
inductive types used placeholder axioms (aType, aProp, aDepProp, ...). They
now use terms built from what the tutorial has introduced by then (sorts,
function types, `∀ p : Prop, p`), without axioms and without inductive types,
so that a checker that declines unknown axioms can check them, and they still
come before the inductive types in the tutorial. proofIrrelevanceUnderBinder
quantifies over the type, the proposition and the functions instead.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Reads susz 0.5.0 files without isReflexive and follows the kernel
renovation rules (Quot in Sort (max 1 u), complete level comparison,
eta for partial applications, unit-like types).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Bump nano-lean

The conflict with the removal of nano-lean is resolved in favor of the pull
request, bringing nano-lean back.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Gruszka 0.2.2

The conflict with gruszka 0.2.0 from master is resolved in favor of the
pull request.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Add Nucleus with bounded renovation support

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Pestka 0.2.1

Co-Authored-By: Claude Opus 5.5 <[email protected]>
It now has the lazy comparison of applied projections (lean4#16613), which
perf/proj-app-lazy-delta tests.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
sparse-name-index and level-index-out-of-order are about how the references
of an export are numbered, but checkers that decline non-standard axioms
declined them for their `axiom foo`. They now export `def foo : Type := Prop`
and `def foo : Sort 2 := Sort 1`, with the same irregular numbering.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…61126

Move Nucleus source to metalogiclabs/nucleus
It includes lean4#15374 (eta for partial recursor applications), so
etaRecStruct and etaRuleK are now ordinary renovation tests that the kernel
checks, and lean4#14896 (theorems opaque to the kernel). Its exporter writes
format version 3.2.0 itself, so the renovation tests no longer write their
own metadata. The official checker, the tests, the tutorial and the
renovation tests all use it; its leanchecker gives every test its expected
verdict but for the tests of changes it does not have yet (complete level
comparison, lean4#15372, lean4#15023).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
It includes lean4#15023 (`Quot` living in `Sort (max 1 u)`), so the renovation
tests no longer replace the type of `Quot` by hand, and their quotient tests
are ordinary tests that the kernel checks. Its leanchecker gives every test
its expected verdict but for the tests of changes it does not have yet
(complete level comparison, lean4#15372).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
A `String` is a sequence of Unicode scalar values (no surrogates), and names
are made of strings, so an export must not have string literals or names
that are not valid UTF-8 or that denote a surrogate. The new bad tests
other/str-* and other/name-* check that checkers reject lone high and low
surrogates and reversed surrogate pairs as JSON escapes, surrogates
encoded as UTF-8 bytes (singly and as a CESU-8 pair), bytes that are not
UTF-8 and an overlong encoding. Most of the string tests equate two such
literals that a lenient decoder maps to the same string (lean4#16877).

The good tests other/str-escape-* check that different JSON spellings of
one string (escapes, escaped surrogate pairs, short escapes) denote the
same string, and the bad test other/str-nul that a string does not end at
an escaped NUL.

The name tests are small stored exports. The string tests are generated
by invalid-utf8/gen.py from an export of a small theorem, because an
export with a string literal is about 0.5 MB.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants