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
The document shows that if no type can be inferred, declarations default to isize and usize. According to this: https://doc.rust-lang.org/book/first-edition/primitive-types.html#numeric-types
This is not the case. Actually doing this on a 64bit machine: let _x = 30000000000;
gives "warning: literal out of range for i32" when compiled. However, let _x: isize = 30000000000;
gives no issues whatsoever.
The text was updated successfully, but these errors were encountered:
The document shows that if no type can be inferred, declarations default to isize and usize. According to this:
https://doc.rust-lang.org/book/first-edition/primitive-types.html#numeric-types
This is not the case. Actually doing this on a 64bit machine:
let _x = 30000000000;
gives "warning: literal out of range for i32" when compiled. However,
let _x: isize = 30000000000;
gives no issues whatsoever.
The text was updated successfully, but these errors were encountered: