meta: port ironwood's extended AxiomCheck - #20
Merged
Merged
Conversation
daira
commented
Aug 10, 2026
daira
marked this pull request as ready for review
August 10, 2026 04:17
Replace the minimal assert_axioms/assert_computable with ironwood's extended version. The `+native` flag now requires naming the owning declaration(s) of exactly the native_decide axioms the entry reaches, with provenance checks that reject an axiom merely named like a compiler auxiliary. Both commands also reject compiled-body overrides (`@[implemented_by]`, `@[extern]`) anywhere in the import closure, reject `partial` declarations inside a certificate's evaluated term, and require fully qualified entry names. The regression tests live in a new MetaCheck library outside CompElliptic/, so their forged axioms never enter the production import graph and the source-level sweep scripts do not scan them. TrustBoundary's `+native` entries now name their owners: each Tonelli–Shanks datum owns the two certificates of its primitivity check, and the curve-order entries reach exactly the nsmul witnesses. Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replaces the minimal
assert_axioms/assert_computablewith ironwood's extended version (Zcash/Meta/AxiomCheck.lean), which the two repos now share up to repo-specific references. This is groundwork for re-checking the build with an independent kernel implementation (nanoda): the owner-naming census makes the exact per-usenative_decideaxiom names a build-checked artifact, which is what an external checker's permitted-axiom list needs to pin.What the extended version adds:
+native(D₁, ...)owner lists — a bare+nativepermitted anative_decideaxiom brought in by any declaration entering the dependency cone; entries now name the owning declarations of exactly the axioms reached, and a stale or incomplete list fails the build with the list to write.@[implemented_by]/@[extern]swap what runs without changing the axiom footprint; both commands reject a censused target carrying one, and any override anywhere in the non-ambient import closure.native_decidecertificate must not have evaluated apartialdeclaration (the kernel constant has no body at all). The walk follows@[csimp]replacements, so a future registration ofpadd_eq_paddFastcannot open a gap.assert_computablehardening — rejectsunsafedefinitions (which can inhabit any type by bare self-reference) and an over-broad+choice.opens.The regression tests for forged axioms, doctored
@[implemented_by]bodies, andpartial-backed certificates are ported to a newMetaChecklibrary outsideCompElliptic/: they never enter the production import graph, the source-level sweeps (check_csimp_census.sh,check_native_optin.py) do not scan them, and a plainlake buildstill runs them.TrustBoundary's six+nativeentries now name their owners, build-checked as exact: each Tonelli–Shanks datum owns the two certificates of its primitivity check (ax_1,ax_2), and the curve-order entries reach exactly the nsmul witnesses' axioms (ax_1_1).🤖 Claude Fable 5