]> git.lizzy.rs Git - rust.git/blob - tests/ui/types.fixed
Auto merge of #4314 - chansuke:add-negation-to-is_empty, r=flip1995
[rust.git] / tests / ui / types.fixed
1 // run-rustfix
2
3 #![allow(dead_code, unused_variables)]
4
5 // should not warn on lossy casting in constant types
6 // because not supported yet
7 const C: i32 = 42;
8 const C_I64: i64 = C as i64;
9
10 fn main() {
11     // should suggest i64::from(c)
12     let c: i32 = 42;
13     let c_i64: i64 = i64::from(c);
14 }