Skip to content

Remove outdated comment about non-copy unions #1872

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

Merged
merged 1 commit into from
Jul 1, 2025

Conversation

ehuss
Copy link
Contributor

@ehuss ehuss commented Jun 27, 2025

I'm not sure when exactly this was removed, but non-copy union fields aren't allowed, and there is no nightly feature to allow them AFAIK.

This was discussed in the tracking issue rust-lang/rust#55149 and various changes like rust-lang/rust#97995 on what is allowed, but I did not dig down to find the exact change that closed the door.

The allowed field kinds are described in items.union.field-restrictions.

Also, in general the reference shouldn't be referring to unstable features.

I'm not sure when exactly this was removed, but non-copy union fields
aren't allowed, and there is no nightly feature to allow them AFAIK.

There was various discussion in the tracking issue
rust-lang/rust#55149 and various changes like
rust-lang/rust#97995 on what is allowed, but I
did not dig down to find the exact change that closed the door.

The allowed field kinds are described in items.union.field-restrictions.

Also, in general the reference shouldn't be referring to unstable
features.
@rustbot rustbot added the S-waiting-on-review Status: The marked PR is awaiting review from a maintainer label Jun 27, 2025
@traviscross traviscross added this pull request to the merge queue Jul 1, 2025
Merged via the queue into rust-lang:master with commit 051f1e5 Jul 1, 2025
5 checks passed
@rustbot rustbot removed the S-waiting-on-review Status: The marked PR is awaiting review from a maintainer label Jul 1, 2025
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.

3 participants