News for hackers. Stuff that matters.
Re:Rust 1.45 by 95th on Friday July 17, 2020 @01:49AM (#23867481)
Then what do you propose for replacement? C++ style casts `(int) x` ?
Re:Rust 1.45 by devit on Friday July 17, 2020 @03:59AM (#23868271)
into()/try_into() and methods designed for each of the other cases (e.g. truncate(), saturating_to_int(), approx_to_float(), etc.)
Re:Rust 1.45 by erk__ on Friday July 17, 2020 @03:07AM (#23867953)
Using `x.into()` instead or `x.try_into()` if it can fail.