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
During the last training I did, this was a nice moment to re-inforce the point that Rust is quite strict on integer conversions (although I'd prefer these kind of safe upcasts were allowed). I.e.
Either we fix this error, but that would require finding a 'nicer' example; I'm pretty sure those exists.
Or we own up to it (we could even add a slide after this one that goes "woops, it didnd't compile, here's how to fix it")
@hdoordt
https://github.com/tweedegolf/rust-workshop/blob/eb901ff9b2984177e5baea397abd335be52f1df7/slides/A-intro-to-rust.md#L1995
All these a,b,c,d have to be cast to u32. But that doesn't look nice...
So... Should we change it?
The text was updated successfully, but these errors were encountered: