1 error[E0308]: mismatched types
2 --> $DIR/numeric-cast.rs:23:18
4 LL | foo::<usize>(x_u64);
5 | ^^^^^ expected `usize`, found `u64`
7 help: you can convert a `u64` to a `usize` and panic if the converted value doesn't fit
9 LL | foo::<usize>(x_u64.try_into().unwrap());
10 | ^^^^^^^^^^^^^^^^^^^^^^^^^
12 error[E0308]: mismatched types
13 --> $DIR/numeric-cast.rs:25:18
15 LL | foo::<usize>(x_u32);
16 | ^^^^^ expected `usize`, found `u32`
18 help: you can convert a `u32` to a `usize` and panic if the converted value doesn't fit
20 LL | foo::<usize>(x_u32.try_into().unwrap());
21 | ^^^^^^^^^^^^^^^^^^^^^^^^^
23 error[E0308]: mismatched types
24 --> $DIR/numeric-cast.rs:27:18
26 LL | foo::<usize>(x_u16);
29 | expected `usize`, found `u16`
30 | help: you can convert a `u16` to a `usize`: `x_u16.into()`
32 error[E0308]: mismatched types
33 --> $DIR/numeric-cast.rs:29:18
35 LL | foo::<usize>(x_u8);
38 | expected `usize`, found `u8`
39 | help: you can convert a `u8` to a `usize`: `x_u8.into()`
41 error[E0308]: mismatched types
42 --> $DIR/numeric-cast.rs:31:18
44 LL | foo::<usize>(x_isize);
45 | ^^^^^^^ expected `usize`, found `isize`
47 help: you can convert an `isize` to a `usize` and panic if the converted value doesn't fit
49 LL | foo::<usize>(x_isize.try_into().unwrap());
50 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
52 error[E0308]: mismatched types
53 --> $DIR/numeric-cast.rs:33:18
55 LL | foo::<usize>(x_i64);
56 | ^^^^^ expected `usize`, found `i64`
58 help: you can convert an `i64` to a `usize` and panic if the converted value doesn't fit
60 LL | foo::<usize>(x_i64.try_into().unwrap());
61 | ^^^^^^^^^^^^^^^^^^^^^^^^^
63 error[E0308]: mismatched types
64 --> $DIR/numeric-cast.rs:35:18
66 LL | foo::<usize>(x_i32);
67 | ^^^^^ expected `usize`, found `i32`
69 help: you can convert an `i32` to a `usize` and panic if the converted value doesn't fit
71 LL | foo::<usize>(x_i32.try_into().unwrap());
72 | ^^^^^^^^^^^^^^^^^^^^^^^^^
74 error[E0308]: mismatched types
75 --> $DIR/numeric-cast.rs:37:18
77 LL | foo::<usize>(x_i16);
78 | ^^^^^ expected `usize`, found `i16`
80 help: you can convert an `i16` to a `usize` and panic if the converted value doesn't fit
82 LL | foo::<usize>(x_i16.try_into().unwrap());
83 | ^^^^^^^^^^^^^^^^^^^^^^^^^
85 error[E0308]: mismatched types
86 --> $DIR/numeric-cast.rs:39:18
88 LL | foo::<usize>(x_i8);
89 | ^^^^ expected `usize`, found `i8`
91 help: you can convert an `i8` to a `usize` and panic if the converted value doesn't fit
93 LL | foo::<usize>(x_i8.try_into().unwrap());
94 | ^^^^^^^^^^^^^^^^^^^^^^^^
96 error[E0308]: mismatched types
97 --> $DIR/numeric-cast.rs:44:18
99 LL | foo::<isize>(x_usize);
100 | ^^^^^^^ expected `isize`, found `usize`
102 help: you can convert a `usize` to an `isize` and panic if the converted value doesn't fit
104 LL | foo::<isize>(x_usize.try_into().unwrap());
105 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
107 error[E0308]: mismatched types
108 --> $DIR/numeric-cast.rs:46:18
110 LL | foo::<isize>(x_u64);
111 | ^^^^^ expected `isize`, found `u64`
113 help: you can convert a `u64` to an `isize` and panic if the converted value doesn't fit
115 LL | foo::<isize>(x_u64.try_into().unwrap());
116 | ^^^^^^^^^^^^^^^^^^^^^^^^^
118 error[E0308]: mismatched types
119 --> $DIR/numeric-cast.rs:48:18
121 LL | foo::<isize>(x_u32);
122 | ^^^^^ expected `isize`, found `u32`
124 help: you can convert a `u32` to an `isize` and panic if the converted value doesn't fit
126 LL | foo::<isize>(x_u32.try_into().unwrap());
127 | ^^^^^^^^^^^^^^^^^^^^^^^^^
129 error[E0308]: mismatched types
130 --> $DIR/numeric-cast.rs:50:18
132 LL | foo::<isize>(x_u16);
133 | ^^^^^ expected `isize`, found `u16`
135 help: you can convert a `u16` to an `isize` and panic if the converted value doesn't fit
137 LL | foo::<isize>(x_u16.try_into().unwrap());
138 | ^^^^^^^^^^^^^^^^^^^^^^^^^
140 error[E0308]: mismatched types
141 --> $DIR/numeric-cast.rs:52:18
143 LL | foo::<isize>(x_u8);
146 | expected `isize`, found `u8`
147 | help: you can convert a `u8` to an `isize`: `x_u8.into()`
149 error[E0308]: mismatched types
150 --> $DIR/numeric-cast.rs:55:18
152 LL | foo::<isize>(x_i64);
153 | ^^^^^ expected `isize`, found `i64`
155 help: you can convert an `i64` to an `isize` and panic if the converted value doesn't fit
157 LL | foo::<isize>(x_i64.try_into().unwrap());
158 | ^^^^^^^^^^^^^^^^^^^^^^^^^
160 error[E0308]: mismatched types
161 --> $DIR/numeric-cast.rs:57:18
163 LL | foo::<isize>(x_i32);
164 | ^^^^^ expected `isize`, found `i32`
166 help: you can convert an `i32` to an `isize` and panic if the converted value doesn't fit
168 LL | foo::<isize>(x_i32.try_into().unwrap());
169 | ^^^^^^^^^^^^^^^^^^^^^^^^^
171 error[E0308]: mismatched types
172 --> $DIR/numeric-cast.rs:59:18
174 LL | foo::<isize>(x_i16);
177 | expected `isize`, found `i16`
178 | help: you can convert an `i16` to an `isize`: `x_i16.into()`
180 error[E0308]: mismatched types
181 --> $DIR/numeric-cast.rs:61:18
183 LL | foo::<isize>(x_i8);
186 | expected `isize`, found `i8`
187 | help: you can convert an `i8` to an `isize`: `x_i8.into()`
189 error[E0308]: mismatched types
190 --> $DIR/numeric-cast.rs:66:16
192 LL | foo::<u64>(x_usize);
193 | ^^^^^^^ expected `u64`, found `usize`
195 help: you can convert a `usize` to a `u64` and panic if the converted value doesn't fit
197 LL | foo::<u64>(x_usize.try_into().unwrap());
198 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
200 error[E0308]: mismatched types
201 --> $DIR/numeric-cast.rs:69:16
203 LL | foo::<u64>(x_u32);
206 | expected `u64`, found `u32`
207 | help: you can convert a `u32` to a `u64`: `x_u32.into()`
209 error[E0308]: mismatched types
210 --> $DIR/numeric-cast.rs:71:16
212 LL | foo::<u64>(x_u16);
215 | expected `u64`, found `u16`
216 | help: you can convert a `u16` to a `u64`: `x_u16.into()`
218 error[E0308]: mismatched types
219 --> $DIR/numeric-cast.rs:73:16
221 LL | foo::<u64>(x_u8);
224 | expected `u64`, found `u8`
225 | help: you can convert a `u8` to a `u64`: `x_u8.into()`
227 error[E0308]: mismatched types
228 --> $DIR/numeric-cast.rs:75:16
230 LL | foo::<u64>(x_isize);
231 | ^^^^^^^ expected `u64`, found `isize`
233 help: you can convert an `isize` to a `u64` and panic if the converted value doesn't fit
235 LL | foo::<u64>(x_isize.try_into().unwrap());
236 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
238 error[E0308]: mismatched types
239 --> $DIR/numeric-cast.rs:77:16
241 LL | foo::<u64>(x_i64);
242 | ^^^^^ expected `u64`, found `i64`
244 help: you can convert an `i64` to a `u64` and panic if the converted value doesn't fit
246 LL | foo::<u64>(x_i64.try_into().unwrap());
247 | ^^^^^^^^^^^^^^^^^^^^^^^^^
249 error[E0308]: mismatched types
250 --> $DIR/numeric-cast.rs:79:16
252 LL | foo::<u64>(x_i32);
253 | ^^^^^ expected `u64`, found `i32`
255 help: you can convert an `i32` to a `u64` and panic if the converted value doesn't fit
257 LL | foo::<u64>(x_i32.try_into().unwrap());
258 | ^^^^^^^^^^^^^^^^^^^^^^^^^
260 error[E0308]: mismatched types
261 --> $DIR/numeric-cast.rs:81:16
263 LL | foo::<u64>(x_i16);
264 | ^^^^^ expected `u64`, found `i16`
266 help: you can convert an `i16` to a `u64` and panic if the converted value doesn't fit
268 LL | foo::<u64>(x_i16.try_into().unwrap());
269 | ^^^^^^^^^^^^^^^^^^^^^^^^^
271 error[E0308]: mismatched types
272 --> $DIR/numeric-cast.rs:83:16
274 LL | foo::<u64>(x_i8);
275 | ^^^^ expected `u64`, found `i8`
277 help: you can convert an `i8` to a `u64` and panic if the converted value doesn't fit
279 LL | foo::<u64>(x_i8.try_into().unwrap());
280 | ^^^^^^^^^^^^^^^^^^^^^^^^
282 error[E0308]: mismatched types
283 --> $DIR/numeric-cast.rs:88:16
285 LL | foo::<i64>(x_usize);
286 | ^^^^^^^ expected `i64`, found `usize`
288 help: you can convert a `usize` to an `i64` and panic if the converted value doesn't fit
290 LL | foo::<i64>(x_usize.try_into().unwrap());
291 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
293 error[E0308]: mismatched types
294 --> $DIR/numeric-cast.rs:90:16
296 LL | foo::<i64>(x_u64);
297 | ^^^^^ expected `i64`, found `u64`
299 help: you can convert a `u64` to an `i64` and panic if the converted value doesn't fit
301 LL | foo::<i64>(x_u64.try_into().unwrap());
302 | ^^^^^^^^^^^^^^^^^^^^^^^^^
304 error[E0308]: mismatched types
305 --> $DIR/numeric-cast.rs:92:16
307 LL | foo::<i64>(x_u32);
310 | expected `i64`, found `u32`
311 | help: you can convert a `u32` to an `i64`: `x_u32.into()`
313 error[E0308]: mismatched types
314 --> $DIR/numeric-cast.rs:94:16
316 LL | foo::<i64>(x_u16);
319 | expected `i64`, found `u16`
320 | help: you can convert a `u16` to an `i64`: `x_u16.into()`
322 error[E0308]: mismatched types
323 --> $DIR/numeric-cast.rs:96:16
325 LL | foo::<i64>(x_u8);
328 | expected `i64`, found `u8`
329 | help: you can convert a `u8` to an `i64`: `x_u8.into()`
331 error[E0308]: mismatched types
332 --> $DIR/numeric-cast.rs:98:16
334 LL | foo::<i64>(x_isize);
335 | ^^^^^^^ expected `i64`, found `isize`
337 help: you can convert an `isize` to an `i64` and panic if the converted value doesn't fit
339 LL | foo::<i64>(x_isize.try_into().unwrap());
340 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
342 error[E0308]: mismatched types
343 --> $DIR/numeric-cast.rs:101:16
345 LL | foo::<i64>(x_i32);
348 | expected `i64`, found `i32`
349 | help: you can convert an `i32` to an `i64`: `x_i32.into()`
351 error[E0308]: mismatched types
352 --> $DIR/numeric-cast.rs:103:16
354 LL | foo::<i64>(x_i16);
357 | expected `i64`, found `i16`
358 | help: you can convert an `i16` to an `i64`: `x_i16.into()`
360 error[E0308]: mismatched types
361 --> $DIR/numeric-cast.rs:105:16
363 LL | foo::<i64>(x_i8);
366 | expected `i64`, found `i8`
367 | help: you can convert an `i8` to an `i64`: `x_i8.into()`
369 error[E0308]: mismatched types
370 --> $DIR/numeric-cast.rs:110:16
372 LL | foo::<u32>(x_usize);
373 | ^^^^^^^ expected `u32`, found `usize`
375 help: you can convert a `usize` to a `u32` and panic if the converted value doesn't fit
377 LL | foo::<u32>(x_usize.try_into().unwrap());
378 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
380 error[E0308]: mismatched types
381 --> $DIR/numeric-cast.rs:112:16
383 LL | foo::<u32>(x_u64);
384 | ^^^^^ expected `u32`, found `u64`
386 help: you can convert a `u64` to a `u32` and panic if the converted value doesn't fit
388 LL | foo::<u32>(x_u64.try_into().unwrap());
389 | ^^^^^^^^^^^^^^^^^^^^^^^^^
391 error[E0308]: mismatched types
392 --> $DIR/numeric-cast.rs:115:16
394 LL | foo::<u32>(x_u16);
397 | expected `u32`, found `u16`
398 | help: you can convert a `u16` to a `u32`: `x_u16.into()`
400 error[E0308]: mismatched types
401 --> $DIR/numeric-cast.rs:117:16
403 LL | foo::<u32>(x_u8);
406 | expected `u32`, found `u8`
407 | help: you can convert a `u8` to a `u32`: `x_u8.into()`
409 error[E0308]: mismatched types
410 --> $DIR/numeric-cast.rs:119:16
412 LL | foo::<u32>(x_isize);
413 | ^^^^^^^ expected `u32`, found `isize`
415 help: you can convert an `isize` to a `u32` and panic if the converted value doesn't fit
417 LL | foo::<u32>(x_isize.try_into().unwrap());
418 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
420 error[E0308]: mismatched types
421 --> $DIR/numeric-cast.rs:121:16
423 LL | foo::<u32>(x_i64);
424 | ^^^^^ expected `u32`, found `i64`
426 help: you can convert an `i64` to a `u32` and panic if the converted value doesn't fit
428 LL | foo::<u32>(x_i64.try_into().unwrap());
429 | ^^^^^^^^^^^^^^^^^^^^^^^^^
431 error[E0308]: mismatched types
432 --> $DIR/numeric-cast.rs:123:16
434 LL | foo::<u32>(x_i32);
435 | ^^^^^ expected `u32`, found `i32`
437 help: you can convert an `i32` to a `u32` and panic if the converted value doesn't fit
439 LL | foo::<u32>(x_i32.try_into().unwrap());
440 | ^^^^^^^^^^^^^^^^^^^^^^^^^
442 error[E0308]: mismatched types
443 --> $DIR/numeric-cast.rs:125:16
445 LL | foo::<u32>(x_i16);
446 | ^^^^^ expected `u32`, found `i16`
448 help: you can convert an `i16` to a `u32` and panic if the converted value doesn't fit
450 LL | foo::<u32>(x_i16.try_into().unwrap());
451 | ^^^^^^^^^^^^^^^^^^^^^^^^^
453 error[E0308]: mismatched types
454 --> $DIR/numeric-cast.rs:127:16
456 LL | foo::<u32>(x_i8);
457 | ^^^^ expected `u32`, found `i8`
459 help: you can convert an `i8` to a `u32` and panic if the converted value doesn't fit
461 LL | foo::<u32>(x_i8.try_into().unwrap());
462 | ^^^^^^^^^^^^^^^^^^^^^^^^
464 error[E0308]: mismatched types
465 --> $DIR/numeric-cast.rs:132:16
467 LL | foo::<i32>(x_usize);
468 | ^^^^^^^ expected `i32`, found `usize`
470 help: you can convert a `usize` to an `i32` and panic if the converted value doesn't fit
472 LL | foo::<i32>(x_usize.try_into().unwrap());
473 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
475 error[E0308]: mismatched types
476 --> $DIR/numeric-cast.rs:134:16
478 LL | foo::<i32>(x_u64);
479 | ^^^^^ expected `i32`, found `u64`
481 help: you can convert a `u64` to an `i32` and panic if the converted value doesn't fit
483 LL | foo::<i32>(x_u64.try_into().unwrap());
484 | ^^^^^^^^^^^^^^^^^^^^^^^^^
486 error[E0308]: mismatched types
487 --> $DIR/numeric-cast.rs:136:16
489 LL | foo::<i32>(x_u32);
490 | ^^^^^ expected `i32`, found `u32`
492 help: you can convert a `u32` to an `i32` and panic if the converted value doesn't fit
494 LL | foo::<i32>(x_u32.try_into().unwrap());
495 | ^^^^^^^^^^^^^^^^^^^^^^^^^
497 error[E0308]: mismatched types
498 --> $DIR/numeric-cast.rs:138:16
500 LL | foo::<i32>(x_u16);
503 | expected `i32`, found `u16`
504 | help: you can convert a `u16` to an `i32`: `x_u16.into()`
506 error[E0308]: mismatched types
507 --> $DIR/numeric-cast.rs:140:16
509 LL | foo::<i32>(x_u8);
512 | expected `i32`, found `u8`
513 | help: you can convert a `u8` to an `i32`: `x_u8.into()`
515 error[E0308]: mismatched types
516 --> $DIR/numeric-cast.rs:142:16
518 LL | foo::<i32>(x_isize);
519 | ^^^^^^^ expected `i32`, found `isize`
521 help: you can convert an `isize` to an `i32` and panic if the converted value doesn't fit
523 LL | foo::<i32>(x_isize.try_into().unwrap());
524 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
526 error[E0308]: mismatched types
527 --> $DIR/numeric-cast.rs:144:16
529 LL | foo::<i32>(x_i64);
530 | ^^^^^ expected `i32`, found `i64`
532 help: you can convert an `i64` to an `i32` and panic if the converted value doesn't fit
534 LL | foo::<i32>(x_i64.try_into().unwrap());
535 | ^^^^^^^^^^^^^^^^^^^^^^^^^
537 error[E0308]: mismatched types
538 --> $DIR/numeric-cast.rs:147:16
540 LL | foo::<i32>(x_i16);
543 | expected `i32`, found `i16`
544 | help: you can convert an `i16` to an `i32`: `x_i16.into()`
546 error[E0308]: mismatched types
547 --> $DIR/numeric-cast.rs:149:16
549 LL | foo::<i32>(x_i8);
552 | expected `i32`, found `i8`
553 | help: you can convert an `i8` to an `i32`: `x_i8.into()`
555 error[E0308]: mismatched types
556 --> $DIR/numeric-cast.rs:154:16
558 LL | foo::<u16>(x_usize);
559 | ^^^^^^^ expected `u16`, found `usize`
561 help: you can convert a `usize` to a `u16` and panic if the converted value doesn't fit
563 LL | foo::<u16>(x_usize.try_into().unwrap());
564 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
566 error[E0308]: mismatched types
567 --> $DIR/numeric-cast.rs:156:16
569 LL | foo::<u16>(x_u64);
570 | ^^^^^ expected `u16`, found `u64`
572 help: you can convert a `u64` to a `u16` and panic if the converted value doesn't fit
574 LL | foo::<u16>(x_u64.try_into().unwrap());
575 | ^^^^^^^^^^^^^^^^^^^^^^^^^
577 error[E0308]: mismatched types
578 --> $DIR/numeric-cast.rs:158:16
580 LL | foo::<u16>(x_u32);
581 | ^^^^^ expected `u16`, found `u32`
583 help: you can convert a `u32` to a `u16` and panic if the converted value doesn't fit
585 LL | foo::<u16>(x_u32.try_into().unwrap());
586 | ^^^^^^^^^^^^^^^^^^^^^^^^^
588 error[E0308]: mismatched types
589 --> $DIR/numeric-cast.rs:161:16
591 LL | foo::<u16>(x_u8);
594 | expected `u16`, found `u8`
595 | help: you can convert a `u8` to a `u16`: `x_u8.into()`
597 error[E0308]: mismatched types
598 --> $DIR/numeric-cast.rs:163:16
600 LL | foo::<u16>(x_isize);
601 | ^^^^^^^ expected `u16`, found `isize`
603 help: you can convert an `isize` to a `u16` and panic if the converted value doesn't fit
605 LL | foo::<u16>(x_isize.try_into().unwrap());
606 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
608 error[E0308]: mismatched types
609 --> $DIR/numeric-cast.rs:165:16
611 LL | foo::<u16>(x_i64);
612 | ^^^^^ expected `u16`, found `i64`
614 help: you can convert an `i64` to a `u16` and panic if the converted value doesn't fit
616 LL | foo::<u16>(x_i64.try_into().unwrap());
617 | ^^^^^^^^^^^^^^^^^^^^^^^^^
619 error[E0308]: mismatched types
620 --> $DIR/numeric-cast.rs:167:16
622 LL | foo::<u16>(x_i32);
623 | ^^^^^ expected `u16`, found `i32`
625 help: you can convert an `i32` to a `u16` and panic if the converted value doesn't fit
627 LL | foo::<u16>(x_i32.try_into().unwrap());
628 | ^^^^^^^^^^^^^^^^^^^^^^^^^
630 error[E0308]: mismatched types
631 --> $DIR/numeric-cast.rs:169:16
633 LL | foo::<u16>(x_i16);
634 | ^^^^^ expected `u16`, found `i16`
636 help: you can convert an `i16` to a `u16` and panic if the converted value doesn't fit
638 LL | foo::<u16>(x_i16.try_into().unwrap());
639 | ^^^^^^^^^^^^^^^^^^^^^^^^^
641 error[E0308]: mismatched types
642 --> $DIR/numeric-cast.rs:171:16
644 LL | foo::<u16>(x_i8);
645 | ^^^^ expected `u16`, found `i8`
647 help: you can convert an `i8` to a `u16` and panic if the converted value doesn't fit
649 LL | foo::<u16>(x_i8.try_into().unwrap());
650 | ^^^^^^^^^^^^^^^^^^^^^^^^
652 error[E0308]: mismatched types
653 --> $DIR/numeric-cast.rs:176:16
655 LL | foo::<i16>(x_usize);
656 | ^^^^^^^ expected `i16`, found `usize`
658 help: you can convert a `usize` to an `i16` and panic if the converted value doesn't fit
660 LL | foo::<i16>(x_usize.try_into().unwrap());
661 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
663 error[E0308]: mismatched types
664 --> $DIR/numeric-cast.rs:178:16
666 LL | foo::<i16>(x_u64);
667 | ^^^^^ expected `i16`, found `u64`
669 help: you can convert a `u64` to an `i16` and panic if the converted value doesn't fit
671 LL | foo::<i16>(x_u64.try_into().unwrap());
672 | ^^^^^^^^^^^^^^^^^^^^^^^^^
674 error[E0308]: mismatched types
675 --> $DIR/numeric-cast.rs:180:16
677 LL | foo::<i16>(x_u32);
678 | ^^^^^ expected `i16`, found `u32`
680 help: you can convert a `u32` to an `i16` and panic if the converted value doesn't fit
682 LL | foo::<i16>(x_u32.try_into().unwrap());
683 | ^^^^^^^^^^^^^^^^^^^^^^^^^
685 error[E0308]: mismatched types
686 --> $DIR/numeric-cast.rs:182:16
688 LL | foo::<i16>(x_u16);
689 | ^^^^^ expected `i16`, found `u16`
691 help: you can convert a `u16` to an `i16` and panic if the converted value doesn't fit
693 LL | foo::<i16>(x_u16.try_into().unwrap());
694 | ^^^^^^^^^^^^^^^^^^^^^^^^^
696 error[E0308]: mismatched types
697 --> $DIR/numeric-cast.rs:184:16
699 LL | foo::<i16>(x_u8);
702 | expected `i16`, found `u8`
703 | help: you can convert a `u8` to an `i16`: `x_u8.into()`
705 error[E0308]: mismatched types
706 --> $DIR/numeric-cast.rs:186:16
708 LL | foo::<i16>(x_isize);
709 | ^^^^^^^ expected `i16`, found `isize`
711 help: you can convert an `isize` to an `i16` and panic if the converted value doesn't fit
713 LL | foo::<i16>(x_isize.try_into().unwrap());
714 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
716 error[E0308]: mismatched types
717 --> $DIR/numeric-cast.rs:188:16
719 LL | foo::<i16>(x_i64);
720 | ^^^^^ expected `i16`, found `i64`
722 help: you can convert an `i64` to an `i16` and panic if the converted value doesn't fit
724 LL | foo::<i16>(x_i64.try_into().unwrap());
725 | ^^^^^^^^^^^^^^^^^^^^^^^^^
727 error[E0308]: mismatched types
728 --> $DIR/numeric-cast.rs:190:16
730 LL | foo::<i16>(x_i32);
731 | ^^^^^ expected `i16`, found `i32`
733 help: you can convert an `i32` to an `i16` and panic if the converted value doesn't fit
735 LL | foo::<i16>(x_i32.try_into().unwrap());
736 | ^^^^^^^^^^^^^^^^^^^^^^^^^
738 error[E0308]: mismatched types
739 --> $DIR/numeric-cast.rs:193:16
741 LL | foo::<i16>(x_i8);
744 | expected `i16`, found `i8`
745 | help: you can convert an `i8` to an `i16`: `x_i8.into()`
747 error[E0308]: mismatched types
748 --> $DIR/numeric-cast.rs:198:15
750 LL | foo::<u8>(x_usize);
751 | ^^^^^^^ expected `u8`, found `usize`
753 help: you can convert a `usize` to a `u8` and panic if the converted value doesn't fit
755 LL | foo::<u8>(x_usize.try_into().unwrap());
756 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
758 error[E0308]: mismatched types
759 --> $DIR/numeric-cast.rs:200:15
761 LL | foo::<u8>(x_u64);
762 | ^^^^^ expected `u8`, found `u64`
764 help: you can convert a `u64` to a `u8` and panic if the converted value doesn't fit
766 LL | foo::<u8>(x_u64.try_into().unwrap());
767 | ^^^^^^^^^^^^^^^^^^^^^^^^^
769 error[E0308]: mismatched types
770 --> $DIR/numeric-cast.rs:202:15
772 LL | foo::<u8>(x_u32);
773 | ^^^^^ expected `u8`, found `u32`
775 help: you can convert a `u32` to a `u8` and panic if the converted value doesn't fit
777 LL | foo::<u8>(x_u32.try_into().unwrap());
778 | ^^^^^^^^^^^^^^^^^^^^^^^^^
780 error[E0308]: mismatched types
781 --> $DIR/numeric-cast.rs:204:15
783 LL | foo::<u8>(x_u16);
784 | ^^^^^ expected `u8`, found `u16`
786 help: you can convert a `u16` to a `u8` and panic if the converted value doesn't fit
788 LL | foo::<u8>(x_u16.try_into().unwrap());
789 | ^^^^^^^^^^^^^^^^^^^^^^^^^
791 error[E0308]: mismatched types
792 --> $DIR/numeric-cast.rs:207:15
794 LL | foo::<u8>(x_isize);
795 | ^^^^^^^ expected `u8`, found `isize`
797 help: you can convert an `isize` to a `u8` and panic if the converted value doesn't fit
799 LL | foo::<u8>(x_isize.try_into().unwrap());
800 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
802 error[E0308]: mismatched types
803 --> $DIR/numeric-cast.rs:209:15
805 LL | foo::<u8>(x_i64);
806 | ^^^^^ expected `u8`, found `i64`
808 help: you can convert an `i64` to a `u8` and panic if the converted value doesn't fit
810 LL | foo::<u8>(x_i64.try_into().unwrap());
811 | ^^^^^^^^^^^^^^^^^^^^^^^^^
813 error[E0308]: mismatched types
814 --> $DIR/numeric-cast.rs:211:15
816 LL | foo::<u8>(x_i32);
817 | ^^^^^ expected `u8`, found `i32`
819 help: you can convert an `i32` to a `u8` and panic if the converted value doesn't fit
821 LL | foo::<u8>(x_i32.try_into().unwrap());
822 | ^^^^^^^^^^^^^^^^^^^^^^^^^
824 error[E0308]: mismatched types
825 --> $DIR/numeric-cast.rs:213:15
827 LL | foo::<u8>(x_i16);
828 | ^^^^^ expected `u8`, found `i16`
830 help: you can convert an `i16` to a `u8` and panic if the converted value doesn't fit
832 LL | foo::<u8>(x_i16.try_into().unwrap());
833 | ^^^^^^^^^^^^^^^^^^^^^^^^^
835 error[E0308]: mismatched types
836 --> $DIR/numeric-cast.rs:215:15
838 LL | foo::<u8>(x_i8);
839 | ^^^^ expected `u8`, found `i8`
841 help: you can convert an `i8` to a `u8` and panic if the converted value doesn't fit
843 LL | foo::<u8>(x_i8.try_into().unwrap());
844 | ^^^^^^^^^^^^^^^^^^^^^^^^
846 error[E0308]: mismatched types
847 --> $DIR/numeric-cast.rs:220:15
849 LL | foo::<i8>(x_usize);
850 | ^^^^^^^ expected `i8`, found `usize`
852 help: you can convert a `usize` to an `i8` and panic if the converted value doesn't fit
854 LL | foo::<i8>(x_usize.try_into().unwrap());
855 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
857 error[E0308]: mismatched types
858 --> $DIR/numeric-cast.rs:222:15
860 LL | foo::<i8>(x_u64);
861 | ^^^^^ expected `i8`, found `u64`
863 help: you can convert a `u64` to an `i8` and panic if the converted value doesn't fit
865 LL | foo::<i8>(x_u64.try_into().unwrap());
866 | ^^^^^^^^^^^^^^^^^^^^^^^^^
868 error[E0308]: mismatched types
869 --> $DIR/numeric-cast.rs:224:15
871 LL | foo::<i8>(x_u32);
872 | ^^^^^ expected `i8`, found `u32`
874 help: you can convert a `u32` to an `i8` and panic if the converted value doesn't fit
876 LL | foo::<i8>(x_u32.try_into().unwrap());
877 | ^^^^^^^^^^^^^^^^^^^^^^^^^
879 error[E0308]: mismatched types
880 --> $DIR/numeric-cast.rs:226:15
882 LL | foo::<i8>(x_u16);
883 | ^^^^^ expected `i8`, found `u16`
885 help: you can convert a `u16` to an `i8` and panic if the converted value doesn't fit
887 LL | foo::<i8>(x_u16.try_into().unwrap());
888 | ^^^^^^^^^^^^^^^^^^^^^^^^^
890 error[E0308]: mismatched types
891 --> $DIR/numeric-cast.rs:228:15
893 LL | foo::<i8>(x_u8);
894 | ^^^^ expected `i8`, found `u8`
896 help: you can convert a `u8` to an `i8` and panic if the converted value doesn't fit
898 LL | foo::<i8>(x_u8.try_into().unwrap());
899 | ^^^^^^^^^^^^^^^^^^^^^^^^
901 error[E0308]: mismatched types
902 --> $DIR/numeric-cast.rs:230:15
904 LL | foo::<i8>(x_isize);
905 | ^^^^^^^ expected `i8`, found `isize`
907 help: you can convert an `isize` to an `i8` and panic if the converted value doesn't fit
909 LL | foo::<i8>(x_isize.try_into().unwrap());
910 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
912 error[E0308]: mismatched types
913 --> $DIR/numeric-cast.rs:232:15
915 LL | foo::<i8>(x_i64);
916 | ^^^^^ expected `i8`, found `i64`
918 help: you can convert an `i64` to an `i8` and panic if the converted value doesn't fit
920 LL | foo::<i8>(x_i64.try_into().unwrap());
921 | ^^^^^^^^^^^^^^^^^^^^^^^^^
923 error[E0308]: mismatched types
924 --> $DIR/numeric-cast.rs:234:15
926 LL | foo::<i8>(x_i32);
927 | ^^^^^ expected `i8`, found `i32`
929 help: you can convert an `i32` to an `i8` and panic if the converted value doesn't fit
931 LL | foo::<i8>(x_i32.try_into().unwrap());
932 | ^^^^^^^^^^^^^^^^^^^^^^^^^
934 error[E0308]: mismatched types
935 --> $DIR/numeric-cast.rs:236:15
937 LL | foo::<i8>(x_i16);
938 | ^^^^^ expected `i8`, found `i16`
940 help: you can convert an `i16` to an `i8` and panic if the converted value doesn't fit
942 LL | foo::<i8>(x_i16.try_into().unwrap());
943 | ^^^^^^^^^^^^^^^^^^^^^^^^^
945 error[E0308]: mismatched types
946 --> $DIR/numeric-cast.rs:242:16
948 LL | foo::<f64>(x_usize);
949 | ^^^^^^^ expected `f64`, found `usize`
951 help: you can cast a `usize` to an `f64`, producing the floating point representation of the integer,
952 | rounded if necessary
953 LL | foo::<f64>(x_usize as f64);
956 error[E0308]: mismatched types
957 --> $DIR/numeric-cast.rs:244:16
959 LL | foo::<f64>(x_u64);
960 | ^^^^^ expected `f64`, found `u64`
962 help: you can cast a `u64` to an `f64`, producing the floating point representation of the integer,
963 | rounded if necessary
964 LL | foo::<f64>(x_u64 as f64);
967 error[E0308]: mismatched types
968 --> $DIR/numeric-cast.rs:246:16
970 LL | foo::<f64>(x_u32);
971 | ^^^^^ expected `f64`, found `u32`
973 help: you can convert a `u32` to an `f64`, producing the floating point representation of the integer
975 LL | foo::<f64>(x_u32.into());
978 error[E0308]: mismatched types
979 --> $DIR/numeric-cast.rs:248:16
981 LL | foo::<f64>(x_u16);
982 | ^^^^^ expected `f64`, found `u16`
984 help: you can convert a `u16` to an `f64`, producing the floating point representation of the integer
986 LL | foo::<f64>(x_u16.into());
989 error[E0308]: mismatched types
990 --> $DIR/numeric-cast.rs:250:16
992 LL | foo::<f64>(x_u8);
993 | ^^^^ expected `f64`, found `u8`
995 help: you can convert a `u8` to an `f64`, producing the floating point representation of the integer
997 LL | foo::<f64>(x_u8.into());
1000 error[E0308]: mismatched types
1001 --> $DIR/numeric-cast.rs:252:16
1003 LL | foo::<f64>(x_isize);
1004 | ^^^^^^^ expected `f64`, found `isize`
1006 help: you can convert an `isize` to an `f64`, producing the floating point representation of the integer, rounded if necessary
1008 LL | foo::<f64>(x_isize as f64);
1011 error[E0308]: mismatched types
1012 --> $DIR/numeric-cast.rs:254:16
1014 LL | foo::<f64>(x_i64);
1015 | ^^^^^ expected `f64`, found `i64`
1017 help: you can convert an `i64` to an `f64`, producing the floating point representation of the integer, rounded if necessary
1019 LL | foo::<f64>(x_i64 as f64);
1022 error[E0308]: mismatched types
1023 --> $DIR/numeric-cast.rs:256:16
1025 LL | foo::<f64>(x_i32);
1026 | ^^^^^ expected `f64`, found `i32`
1028 help: you can convert an `i32` to an `f64`, producing the floating point representation of the integer
1030 LL | foo::<f64>(x_i32.into());
1033 error[E0308]: mismatched types
1034 --> $DIR/numeric-cast.rs:258:16
1036 LL | foo::<f64>(x_i16);
1037 | ^^^^^ expected `f64`, found `i16`
1039 help: you can convert an `i16` to an `f64`, producing the floating point representation of the integer
1041 LL | foo::<f64>(x_i16.into());
1044 error[E0308]: mismatched types
1045 --> $DIR/numeric-cast.rs:260:16
1047 LL | foo::<f64>(x_i8);
1048 | ^^^^ expected `f64`, found `i8`
1050 help: you can convert an `i8` to an `f64`, producing the floating point representation of the integer
1052 LL | foo::<f64>(x_i8.into());
1055 error[E0308]: mismatched types
1056 --> $DIR/numeric-cast.rs:263:16
1058 LL | foo::<f64>(x_f32);
1061 | expected `f64`, found `f32`
1062 | help: you can convert an `f32` to an `f64`: `x_f32.into()`
1064 error[E0308]: mismatched types
1065 --> $DIR/numeric-cast.rs:266:16
1067 LL | foo::<f32>(x_usize);
1068 | ^^^^^^^ expected `f32`, found `usize`
1070 help: you can cast a `usize` to an `f32`, producing the floating point representation of the integer,
1071 | rounded if necessary
1072 LL | foo::<f32>(x_usize as f32);
1075 error[E0308]: mismatched types
1076 --> $DIR/numeric-cast.rs:268:16
1078 LL | foo::<f32>(x_u64);
1079 | ^^^^^ expected `f32`, found `u64`
1081 help: you can cast a `u64` to an `f32`, producing the floating point representation of the integer,
1082 | rounded if necessary
1083 LL | foo::<f32>(x_u64 as f32);
1086 error[E0308]: mismatched types
1087 --> $DIR/numeric-cast.rs:270:16
1089 LL | foo::<f32>(x_u32);
1090 | ^^^^^ expected `f32`, found `u32`
1092 help: you can cast a `u32` to an `f32`, producing the floating point representation of the integer,
1093 | rounded if necessary
1094 LL | foo::<f32>(x_u32 as f32);
1097 error[E0308]: mismatched types
1098 --> $DIR/numeric-cast.rs:272:16
1100 LL | foo::<f32>(x_u16);
1101 | ^^^^^ expected `f32`, found `u16`
1103 help: you can convert a `u16` to an `f32`, producing the floating point representation of the integer
1105 LL | foo::<f32>(x_u16.into());
1108 error[E0308]: mismatched types
1109 --> $DIR/numeric-cast.rs:274:16
1111 LL | foo::<f32>(x_u8);
1112 | ^^^^ expected `f32`, found `u8`
1114 help: you can convert a `u8` to an `f32`, producing the floating point representation of the integer
1116 LL | foo::<f32>(x_u8.into());
1119 error[E0308]: mismatched types
1120 --> $DIR/numeric-cast.rs:276:16
1122 LL | foo::<f32>(x_isize);
1123 | ^^^^^^^ expected `f32`, found `isize`
1125 help: you can convert an `isize` to an `f32`, producing the floating point representation of the integer, rounded if necessary
1127 LL | foo::<f32>(x_isize as f32);
1130 error[E0308]: mismatched types
1131 --> $DIR/numeric-cast.rs:278:16
1133 LL | foo::<f32>(x_i64);
1134 | ^^^^^ expected `f32`, found `i64`
1136 help: you can convert an `i64` to an `f32`, producing the floating point representation of the integer, rounded if necessary
1138 LL | foo::<f32>(x_i64 as f32);
1141 error[E0308]: mismatched types
1142 --> $DIR/numeric-cast.rs:280:16
1144 LL | foo::<f32>(x_i32);
1145 | ^^^^^ expected `f32`, found `i32`
1147 help: you can convert an `i32` to an `f32`, producing the floating point representation of the integer, rounded if necessary
1149 LL | foo::<f32>(x_i32 as f32);
1152 error[E0308]: mismatched types
1153 --> $DIR/numeric-cast.rs:282:16
1155 LL | foo::<f32>(x_i16);
1156 | ^^^^^ expected `f32`, found `i16`
1158 help: you can convert an `i16` to an `f32`, producing the floating point representation of the integer
1160 LL | foo::<f32>(x_i16.into());
1163 error[E0308]: mismatched types
1164 --> $DIR/numeric-cast.rs:284:16
1166 LL | foo::<f32>(x_i8);
1167 | ^^^^ expected `f32`, found `i8`
1169 help: you can convert an `i8` to an `f32`, producing the floating point representation of the integer
1171 LL | foo::<f32>(x_i8.into());
1174 error[E0308]: mismatched types
1175 --> $DIR/numeric-cast.rs:289:16
1177 LL | foo::<u32>(x_u8 as u16);
1180 | expected `u32`, found `u16`
1181 | help: you can convert a `u16` to a `u32`: `(x_u8 as u16).into()`
1183 error[E0308]: mismatched types
1184 --> $DIR/numeric-cast.rs:291:16
1186 LL | foo::<i32>(-x_i8);
1189 | expected `i32`, found `i8`
1190 | help: you can convert an `i8` to an `i32`: `(-x_i8).into()`
1192 error: aborting due to 113 previous errors
1194 For more information about this error, try `rustc --explain E0308`.