1 error: casting function pointer `foo` to `i8`
2 --> $DIR/fn_to_numeric_cast.rs:8:13
5 | ^^^^^^^^^ help: try: `foo as usize`
7 = note: `-D clippy::fn-to-numeric-cast` implied by `-D warnings`
9 error: casting function pointer `foo` to `i16`
10 --> $DIR/fn_to_numeric_cast.rs:9:13
12 9 | let _ = foo as i16;
13 | ^^^^^^^^^^ help: try: `foo as usize`
15 error: casting function pointer `foo` to `i32`
16 --> $DIR/fn_to_numeric_cast.rs:10:13
18 10 | let _ = foo as i32;
19 | ^^^^^^^^^^ help: try: `foo as usize`
21 error: casting function pointer `foo` to `i64`
22 --> $DIR/fn_to_numeric_cast.rs:11:13
24 11 | let _ = foo as i64;
25 | ^^^^^^^^^^ help: try: `foo as usize`
27 error: casting function pointer `foo` to `i128`
28 --> $DIR/fn_to_numeric_cast.rs:12:13
30 12 | let _ = foo as i128;
31 | ^^^^^^^^^^^ help: try: `foo as usize`
33 error: casting function pointer `foo` to `isize`
34 --> $DIR/fn_to_numeric_cast.rs:13:13
36 13 | let _ = foo as isize;
37 | ^^^^^^^^^^^^ help: try: `foo as usize`
39 error: casting function pointer `foo` to `u8`
40 --> $DIR/fn_to_numeric_cast.rs:15:13
42 15 | let _ = foo as u8;
43 | ^^^^^^^^^ help: try: `foo as usize`
45 error: casting function pointer `foo` to `u16`
46 --> $DIR/fn_to_numeric_cast.rs:16:13
48 16 | let _ = foo as u16;
49 | ^^^^^^^^^^ help: try: `foo as usize`
51 error: casting function pointer `foo` to `u32`
52 --> $DIR/fn_to_numeric_cast.rs:17:13
54 17 | let _ = foo as u32;
55 | ^^^^^^^^^^ help: try: `foo as usize`
57 error: casting function pointer `foo` to `u64`
58 --> $DIR/fn_to_numeric_cast.rs:18:13
60 18 | let _ = foo as u64;
61 | ^^^^^^^^^^ help: try: `foo as usize`
63 error: casting function pointer `foo` to `u128`
64 --> $DIR/fn_to_numeric_cast.rs:19:13
66 19 | let _ = foo as u128;
67 | ^^^^^^^^^^^ help: try: `foo as usize`
69 error: casting function pointer `abc` to `i8`
70 --> $DIR/fn_to_numeric_cast.rs:28:13
72 28 | let _ = abc as i8;
73 | ^^^^^^^^^ help: try: `abc as usize`
75 error: casting function pointer `abc` to `i16`
76 --> $DIR/fn_to_numeric_cast.rs:29:13
78 29 | let _ = abc as i16;
79 | ^^^^^^^^^^ help: try: `abc as usize`
81 error: casting function pointer `abc` to `i32`
82 --> $DIR/fn_to_numeric_cast.rs:30:13
84 30 | let _ = abc as i32;
85 | ^^^^^^^^^^ help: try: `abc as usize`
87 error: casting function pointer `abc` to `i64`
88 --> $DIR/fn_to_numeric_cast.rs:31:13
90 31 | let _ = abc as i64;
91 | ^^^^^^^^^^ help: try: `abc as usize`
93 error: casting function pointer `abc` to `i128`
94 --> $DIR/fn_to_numeric_cast.rs:32:13
96 32 | let _ = abc as i128;
97 | ^^^^^^^^^^^ help: try: `abc as usize`
99 error: casting function pointer `abc` to `isize`
100 --> $DIR/fn_to_numeric_cast.rs:33:13
102 33 | let _ = abc as isize;
103 | ^^^^^^^^^^^^ help: try: `abc as usize`
105 error: casting function pointer `abc` to `u8`
106 --> $DIR/fn_to_numeric_cast.rs:35:13
108 35 | let _ = abc as u8;
109 | ^^^^^^^^^ help: try: `abc as usize`
111 error: casting function pointer `abc` to `u16`
112 --> $DIR/fn_to_numeric_cast.rs:36:13
114 36 | let _ = abc as u16;
115 | ^^^^^^^^^^ help: try: `abc as usize`
117 error: casting function pointer `abc` to `u32`
118 --> $DIR/fn_to_numeric_cast.rs:37:13
120 37 | let _ = abc as u32;
121 | ^^^^^^^^^^ help: try: `abc as usize`
123 error: casting function pointer `abc` to `u64`
124 --> $DIR/fn_to_numeric_cast.rs:38:13
126 38 | let _ = abc as u64;
127 | ^^^^^^^^^^ help: try: `abc as usize`
129 error: casting function pointer `abc` to `u128`
130 --> $DIR/fn_to_numeric_cast.rs:39:13
132 39 | let _ = abc as u128;
133 | ^^^^^^^^^^^ help: try: `abc as usize`
135 error: casting function pointer `f` to `i32`
136 --> $DIR/fn_to_numeric_cast.rs:46:5
139 | ^^^^^^^^ help: try: `f as usize`
141 error: aborting due to 23 previous errors