Re:Rust in 2016
by blub on Saturday August 15, 2015 @07:41AM
(#10065128)
The first case will be detected by -Wconversion, however you have to enable it.
For the second case, correct me if I'm wrong, but I think both float / int and int / float have a float result. In fact, pretty much all operations involving an int and a float will have a float result.
For the second case, correct me if I'm wrong, but I think both float / int and int / float have a float result. In fact, pretty much all operations involving an int and a float will have a float result.