Repository navigation
feat(compiler): for-range loop for i in start..end (W60, R-CG-7) - #834
Merged
Merged
Conversation
Contributor
|
📓 NotebookLM Notebook linked to this PR
This notebook contains session context, decisions, and artifacts for this work. |
Contributor
This was referenced May 24, 2026
This was referenced May 24, 2026
Merged
Closed
Wave 60 (R-CG-7): TokenKind::KwIn, NodeKind::StmtForRange. parse_range_bound helper avoids struct-literal ambiguity. Verilog/C/Rust/Zig codegen. Loop unroller extended. 9 new tests, all pass. 825 total.
gHashTag
force-pushed
the
feat/wave-60/for-range-loop
branch
from
May 30, 2026 15:26
c524959 to
9ea2866
Compare
Contributor
|
📓 NotebookLM Notebook linked to this PR
This notebook contains session context, decisions, and artifacts for this work. |
Contributor
PR DashboardGenerated at: 2026-05-30 15:26:26 UTC
Summary
|
gHashTag
added a commit
that referenced
this pull request
Jun 1, 2026
Wave 60 (R-CG-7): TokenKind::KwIn, NodeKind::StmtForRange. parse_range_bound helper avoids struct-literal ambiguity. Verilog/C/Rust/Zig codegen. Loop unroller extended. 9 new tests, all pass. 825 total. Co-authored-by: Claude <claude@anthropic.com>
gHashTag
added a commit
that referenced
this pull request
Jun 1, 2026
Wave 60 (R-CG-7): TokenKind::KwIn, NodeKind::StmtForRange. parse_range_bound helper avoids struct-literal ambiguity. Verilog/C/Rust/Zig codegen. Loop unroller extended. 9 new tests, all pass. 825 total. Co-authored-by: Claude <claude@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.
Closes #833
Wave 60 (R-CG-7): Range-based for loop
What
for i in start..end { body }syntaxTokenKind::KwInkeyword,NodeKind::StmtForRangenodeparse_range_boundhelper avoids struct-literalName{ }ambiguity (ident followed by{is not treated as struct literal in range context)for (i = start; i < end; i = i + 1) beginfor (int i = start; i < end; i++)for i in start..end {for (start..end) |i| {StmtForRange(unrolls constant ranges ≤ 4)for (items) |x| { }still works unchangedhas_bodycheck widened to include all statement typesTests
9 new inline tests: parse, Verilog/C/Rust/Zig emit, nested for-range, expr bound (0..N), old-for compatibility, loop unroll. All pass. 825 total.