We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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 array size expression needs to be a const expression (I believe). Currently types/array.md only says that it needs to evaluate to usize.
usize
The text was updated successfully, but these errors were encountered:
Yep, that's right. Moreover, currently, the const expression acts as an anonymous constant, so:
fn foo<T>() { let x: [u8; core::mem::size_of::<T>()]; }
is not valid (but this may change...)
Sorry, something went wrong.
cc rust-lang/rust#43408
Successfully merging a pull request may close this issue.
The array size expression needs to be a const expression (I believe). Currently types/array.md only says that it needs to evaluate to
usize
.The text was updated successfully, but these errors were encountered: