Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Drop #[non_exhaustive] from SpecVersion #749

Merged
merged 2 commits into from
Aug 6, 2024

Conversation

Shnatsel
Copy link
Contributor

Adding every new spec version required an API break anyway, so there isn't any benefit to having #[non_exhaustive].

However, this #[non_exhaustive] has caused serious real-world bugs:
#722
#723

So drop it now that we're making a semver-breaking release anyway.

Also drop #[repr(u16)] because it fits into a u8 perfectly fine, and the layout isn't relied on anywhere as far as I can tell. This is semver-breaking too, which is why I'm doing it now.

Signed-off-by: Sergey "Shnatsel" Davidoff <shnatsel@gmail.com>
Signed-off-by: Sergey "Shnatsel" Davidoff <shnatsel@gmail.com>
@Shnatsel Shnatsel requested a review from a team as a code owner July 17, 2024 03:28
@Shnatsel Shnatsel merged commit 1e66664 into CycloneDX:main Aug 6, 2024
14 checks passed
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