Test "bugs/nat-rec-rules"
Expected: ✋ reject · Size: 8.1 KB · Lines: 128 · lean4export: 3.1.0 · Lean: 4.29.1 · 📄 Declaration
Proof of False via incorrect recursor rule validation.
When processing an inductive type declaration, a correct kernel must verify that the generated recursor rules match the ones provided in the export data. A checker that accidentally compares the imported rules against themselves (instead of against independently constructed rules) will accept arbitrary recursor reduction behavior.
This test defines Nat with a wrong Nat.rec succ rule that always returns hzero (ignoring
the induction hypothesis). Combined with a nat literal extension that hardcodes correct
arithmetic for concrete nat literals but falls back to the wrong Nat.rec rules for symbolic
arguments, this creates an inconsistency that yields a proof of False.
Nanoda incorrectly accepted this proof until it was fixed.
| Checker | Result | ⏱️ | 🧠 | |||
|---|---|---|---|---|---|---|
| mathgraph | ✋ | 1 ms | 31.8 MB | |||
| sokonanoda | ✋ | 1 ms | 33.5 MB | |||
| nanoclo | ✋ | 1 ms | 51.8 MB | |||
| con-ron | ✋ | 1 ms | 12.1 MB | |||
| lazylean | ✋ | 1 ms | 21.5 MB | |||
| nanoda | ✋ | 1 ms | 3.1 MB | |||
| nanobruijn | ✋ | 1 ms | 6.9 MB | |||
| con-leche | ✋ | 3 ms | 17.4 MB | |||
| eink0rn | ✋ | 2 ms | 11.6 MB | |||
| ind-models | ✋ | 60 ms | 107.1 MB | |||
| official | ✋ | 30 ms | 67.2 MB | |||
| lean4lean | ✋ | 28 ms | 98.7 MB | |||
| tenet | ✋ | 142 ms | 44.5 MB | |||
| nanoclo-fortran | ✋ | 1 ms | 4.6 MB | |||
| lean4cobol | ✋ | 4 ms | 13.6 MB | |||
| evmlean | ✋ | 861 ms | 132.9 MB | |||
| mini | ✋ | 35 ms | 74.6 MB | |||
| overfull | ✋ | 14.3 s | 46.2 MB | |||
| kiota | ✋ | 1 ms | 7.1 MB | |||
| canonical-min | ✋ | 387 ms | 1.1 GB | |||
| rpylean | ✋ | 1 ms | 4.6 MB | |||
| vow-lean-kernel | ✋ | 93 ms | 8.2 MB | |||
| official-v4.28.0 | ✋ | 37 ms | 74.8 MB | |||
| still-nanoda | ✋ | 1 ms | 3.1 MB | |||
| nyaya | ✋ | 2 ms | 9.4 MB | |||
| parse-only | 👍 | 28 ms | 65.0 MB |