Lean Kernel Arena / nat-rec-rules

Test "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 29.8 MB
ind-models 60 ms 102.7 MB
official-nightly 30 ms 64.9 MB
evmlean 856 ms 133.4 MB
nanoda 1 ms 3.2 MB
mini 35 ms 74.0 MB
lean4lean 28 ms 96.4 MB
sokonanoda 1 ms 29.8 MB
zignodamus 1 ms 4.8 MB
nanoclo 1 ms 49.5 MB
nanobruijn 1 ms 7.1 MB
kiota 1 ms 9.2 MB
official 30 ms 65.8 MB
vow-lean-kernel 93 ms 8.2 MB
rpylean 1 ms 8.5 MB
official-v4.28.0 37 ms 71.5 MB
still-nanoda 1 ms 3.2 MB
nyaya 2 ms 9.5 MB
parse-only 👍 27 ms 60.6 MB