Repository navigation
Declare pragma circom 2.2.0 in every circuit - #158
Closed
OBrezhniev wants to merge 1 commit into
Closed
OBrezhniev wants to merge 1 commit into
OBrezhniev wants to merge 1 commit into
Conversation
The library needs circom 2.2.0, where buses were introduced, but its pragma lines said otherwise: most files declared 2.1.5, seven SMT files 2.1.9, four files 2.0.0, and several had the line indented. A pragma is a minimum the compiler checks against its own version, so a user on 2.1.x got a parse error on the bus syntax rather than a clear version message. Every file under circuits/ and test/circuits/ now declares "pragma circom 2.2.0;" at column 0. test/circuits/tags_specifications.circom is left as is by earlier decision. CHANGES.txt and circuits/README.md, which had described the inconsistent pragmas, now describe the uniform one. Full suite passes; the change is the pragma line only. This reverses upstream's explicit choice of 2.1.5, on the evidence of circom's own release notes. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01D1w729xzwemQigkf3PCisD
Member
Author
|
Closing: the pragma lines are to stay as they are on circomlib_buses. The compiler requirement remains documented in CHANGES.txt. |
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.
Split out of #149 so that review's diff stays about the correctness fixes: this is the one commit that touches every file, and it changes nothing but the
pragmaline (plus the two sentences inCHANGES.txtandcircuits/README.mdthat describe it).Why 2.2.0. The library uses buses, which circom introduced in 2.2.0 (
RELEASES.md, 2024-10-07). The files declared a mix of2.0.0,2.1.5and2.1.9— all below the real floor — so a user on 2.1.x got a parse error onbusinstead of a version refusal.CHANGES.txthad also said 2.1.5. A pragma is the minimum the compiler checks against its own version, so declaring the true floor turns that parse error into a clear message.What changes. Every file under
circuits/andtest/circuits/now declarespragma circom 2.2.0;at column 0 (some had the line indented).test/circuits/tags_specifications.circomis left as is (it is CIVER input, not a circuit). 108 files, 113 insertions, 114 deletions; no constraint is touched.Verified. The tree at this branch's tip is byte-identical to the tip #149 had before the split (
b85175e), on which the full suite passed (118 tests). Not done here, as before: enforcing the floor frompackage.jsonand pinning the circom version CI installs.🤖 Generated with Claude Code
https://claude.ai/code/session_01D1w729xzwemQigkf3PCisD