feat(language): a variable, a constraint and a cased expression declare their shape as dims, as a parameter does - #1634
Merged
Conversation
…re their shape as dims, as a parameter does Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01C8VMbam9FtNjVAzmUYabQV
Merging this PR will not alter performance
Comparing Footnotes
|
FBumann
enabled auto-merge (squash)
September 15, 2026 09:06
fluxopt-release-bot Bot
added a commit
that referenced
this pull request
Sep 15, 2026
🤖 I have created a release *beep* *boop* --- ## [0.0.1-alpha.331](v0.0.1-alpha.330...v0.0.1-alpha.331) (2026-09-15) ### Features * **language:** a variable, a constraint and a cased expression declare their shape as dims, as a parameter does ([#1634](#1634)) ([7bdcdeb](7bdcdeb)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Co-authored-by: fluxopt-release-bot[bot] <307443024+fluxopt-release-bot[bot]@users.noreply.github.com>
3 tasks
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.
Note
The following content was generated by AI.
Follows math-spec to
v0.0.0-alpha.88. A variable, a constraint and a casedexpression now declare their shape as
dims:, the key a parameter alreadyused;
foreach:is gone from the language, so every model file in the tree isrewritten.
alpha.87 is the only release in the range that changes what a file may say
(energy-models/mathspec#429). alpha.86 adds the lookups to the names a
mistyped
whereis answered with, and alpha.88 is documentation. The loweredProgramthis package consumes was already spelleddims, so no engine logicmoved — the rename reaches the model files, the docstrings that quote the key,
and the prose.
pyproject.tomlanduv.lockto alpha.88.foreach:→dims:acrossexamples/,differential/pypsa/rungs/,bench/models/, and the inline specs undertests/.refuse_outside_foreachisrefuse_outside_frame: the word was the retiredkey's, and what it describes is the declaration's frame.
docs/,README.mdand both notebooks follow. No page needed regenerating —the three generators agree with the renamed models.
No alias and no hand-written message for
foreach:; the closed schema's ownerror names the valid keys. No test asserted the old spelling as behaviour, so
no coverage moved.
What was verified, and what was not
Run on this branch's head, against math-spec
5656b11(v0.0.0-alpha.88):Not run: the depth-3 expression sweep, and the CodSpeed job.
bench/carries only model files here, so the harness run is a check that therenamed models still load and solve — it takes no numbers and this PR publishes
none.
The one collision the sweep created
_wide_objective_ofintests/test_arithmetic_laws.pytook aforeachargument and built a local named
dimsfor the dimensions mapping, so renamingthe argument made the second shadow the first and the constraint declared a
mapping where a list belongs:
The local is now
dimensions. It was the only such clash in 205 files, and thesuite caught it.
Incidental lockfile churn
uv lockalso tightened six environment markers it had been carrying loose —pycparser,linkify-it-py,ptyprocessand memray's three. Tool outputrather than an edit of mine, and left as the tool wrote it.
🤖 Generated with Claude Code
https://claude.ai/code/session_01C8VMbam9FtNjVAzmUYabQV
Generated by Claude Code