Repository navigation
feat(t27b): lower [T; N], repeats, text lists and [T] slices like the reference - #6347
Merged
Merged
Conversation
… reference Lower the remaining [N]T spellings in cli/t27b/src/lower.rs and refuse what cannot be matched with named blockers (type [*]T, type [K:V], ExprArrayLiteral sub-kinds). Corpus counted 606 -> 615 of 720, checked pass with tests 314 -> 322, mismatch 0. Closes #6346 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Oct 5, 2026
Closed
Contributor
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 #6346
Refs #6063
What changed
cli/t27b/src/lower.rsnow lowers these[N]Tspellings so each per-test verdict equals t27c gen + zig:[T; N];[v; n]and[_]T{a} ** n. The element is evaluated once and copied forward by doubling, as.{...} ** ndoes;[T]slice parameters given a literal or a local array, mirroring t27c's@constCast(&[_]T{...})andslice_locals.Anything that cannot be matched gets a named refusal:
type [*]Ttype [K:V]ExprArrayLiteral(repeat to slice | text element | text form | repeat count | to slice)[M]T"Module constants are now registered before the signature pass, so a spliced
const Nused in an array type resolves.Corpus (720 files, fixed binary copies, own t27c build + own reference cache)
Tests
t27_array_spellings_repeats_and_slice_arguments: its verdicts (3 pass,repeat_failsfails) were confirmed undert27c test-report.t27_array_spelling_rejections_are_precise: covers 8 named refusals.Reference bugs seen (not fixed here)
const X: [u32; N] = [0; N];.🤖 Generated with Claude Code