You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
E0493: r##"
A type with a destructor was assigned to an invalid type of variable. Erroneous
code example:
struct Foo {
a: u32
}
impl Drop for Foo {
fn drop(&mut self) {}
}
const F : Foo = Foo { a : 0 };
// error: constants are not allowed to have destructors
static S : Foo = Foo { a : 0 };
// error: destructors in statics are an unstable feature
To solve this issue, please use a type which does allow the usage of type with
destructors.
"##,
The text was updated successfully, but these errors were encountered:
I'm going to close this in favor of #34588 which tracks the larger issue of the error index being insufficiently tested as well as not really processed in full. Thanks; this has reminded me that I wanted to devote some time to fixing this 'soon.'
This example (correctly) fails to compile with "error[E0493]: destructors in statics are an unstable feature", but https://doc.rust-lang.org/error-index.html#E0493 is not found.
There is however some documentation in librustc_mir/diagnostics.rs:
The text was updated successfully, but these errors were encountered: