Closed
Description
fn foo(n: usize) {
assert!(n <= u32::MAX as usize);
}
fn main() {}
Gives:
error[E0599]: no associated item named `MAX` found for type `u32` in the current scope
--> ...\test.rs:2:18
|
2 | assert!(n <= u32::MAX as usize);
| ^^^^^^^^ associated item not found in `u32`
error: aborting due to previous error
For more information about this error, try `rustc --explain E0599`.
Perhaps here we want to give a hint where to find the u32::MAX?