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

E0493 is missing from https://doc.rust-lang.org/error-index.html #42170

Closed
glyn opened this issue May 23, 2017 · 2 comments
Closed

E0493 is missing from https://doc.rust-lang.org/error-index.html #42170

glyn opened this issue May 23, 2017 · 2 comments

Comments

@glyn
Copy link

glyn commented May 23, 2017

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:

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.
"##,
@Mark-Simulacrum
Copy link
Member

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.'

@glyn
Copy link
Author

glyn commented May 23, 2017

@Mark-Simulacrum Thanks. I was hoping for an outcome along those lines. :-)

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

No branches or pull requests

2 participants