-
Notifications
You must be signed in to change notification settings - Fork 13.2k
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
The Drop
flag is a footgun for #[repr(C)]
#24585
Comments
triage: P-low |
oops. triage: P-high (but nonetheless not 1.0) |
I feel like this should be stronger than a medium-priority lint. I feel like rustc should reject programs that attempt to In particular, not fixing this by 1.0 would foreclose the ability to change the drop flag after 1.0, since that would change the size / ABI of |
Yeah this label got auto renamed. I'm up'ing the priority |
triage: P-high I'll assign to self too |
( @geofft I'm pretty confident we could fix this post 1.0, e.g. adding new warnings is allowed, and the representation issue would be "just a bug to be fixed." Nonetheless I I do I do want I do want to fix.) |
Lint: warn when mixing `#[repr(C)]` with Drop Fix rust-lang#24585
(imported from improperly closed bug #18380)
As suggested by @huonw:
Until #5016 is done, we really should lint for this scenario. People have run into it
The text was updated successfully, but these errors were encountered: