Skip to content

Remove optional gen parameter from bytes_size and string_size generators#403

Merged
jmid merged 10 commits intoc-cube:mainfrom
jmid:remove-string-bytes-opt-gen
Jan 31, 2026
Merged

Remove optional gen parameter from bytes_size and string_size generators#403
jmid merged 10 commits intoc-cube:mainfrom
jmid:remove-string-bytes-opt-gen

Conversation

@jmid
Copy link
Copy Markdown
Collaborator

@jmid jmid commented Jan 30, 2026

As part of The Great Renaming in 0.90 we kicked a couple of cans further down the road, regarding optional gen parameters to the bytes_size and string_size generators.

From #371 on bytes:

With bytes_size_of added there's no need for the optional ?gen parameter in all 3 variants of bytes_size.
I'll leave to the 1.0.0 release to remove it.

and from #372 on string:

Like for bytes in #371, this postpones the removal of (now redundant) optional ?gen parameters to string_size to the future 1.0.0 release.

To move forward with the 1.0.0 release, this PR thus keeps the promise and removes the redundant ?gen parameter.
This is an API breaking change, which is precisely why it was postponed to the 1.0.0 release, for semantic-versioning-harmony 🌞

Any usage, e.g., bytes_size ~gen size can be easily rewritten to bytes_size_of size gen.

@jmid jmid merged commit 0a2de6e into c-cube:main Jan 31, 2026
24 checks passed
@jmid jmid deleted the remove-string-bytes-opt-gen branch January 31, 2026 23:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant