1720 lines
50 KiB
Plaintext
1720 lines
50 KiB
Plaintext
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:23:16
|
|
|
|
|
LL | x_u8 > x_u16;
|
|
| ---- ^^^^^ expected `u8`, found `u16`
|
|
| |
|
|
| expected because this is `u8`
|
|
|
|
|
help: you can convert `x_u8` from `u8` to `u16`, matching the type of `x_u16`
|
|
|
|
|
LL | u16::from(x_u8) > x_u16;
|
|
| ++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:25:16
|
|
|
|
|
LL | x_u8 > x_u32;
|
|
| ---- ^^^^^ expected `u8`, found `u32`
|
|
| |
|
|
| expected because this is `u8`
|
|
|
|
|
help: you can convert `x_u8` from `u8` to `u32`, matching the type of `x_u32`
|
|
|
|
|
LL | u32::from(x_u8) > x_u32;
|
|
| ++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:27:16
|
|
|
|
|
LL | x_u8 > x_u64;
|
|
| ---- ^^^^^ expected `u8`, found `u64`
|
|
| |
|
|
| expected because this is `u8`
|
|
|
|
|
help: you can convert `x_u8` from `u8` to `u64`, matching the type of `x_u64`
|
|
|
|
|
LL | u64::from(x_u8) > x_u64;
|
|
| ++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:29:16
|
|
|
|
|
LL | x_u8 > x_u128;
|
|
| ---- ^^^^^^ expected `u8`, found `u128`
|
|
| |
|
|
| expected because this is `u8`
|
|
|
|
|
help: you can convert `x_u8` from `u8` to `u128`, matching the type of `x_u128`
|
|
|
|
|
LL | u128::from(x_u8) > x_u128;
|
|
| +++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:31:16
|
|
|
|
|
LL | x_u8 > x_usize;
|
|
| ---- ^^^^^^^ expected `u8`, found `usize`
|
|
| |
|
|
| expected because this is `u8`
|
|
|
|
|
help: you can convert `x_u8` from `u8` to `usize`, matching the type of `x_usize`
|
|
|
|
|
LL | usize::from(x_u8) > x_usize;
|
|
| ++++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:34:17
|
|
|
|
|
LL | x_u16 > x_u8;
|
|
| ----- ^^^^ expected `u16`, found `u8`
|
|
| |
|
|
| expected because this is `u16`
|
|
|
|
|
help: you can convert a `u8` to a `u16`
|
|
|
|
|
LL | x_u16 > x_u8.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:36:17
|
|
|
|
|
LL | x_u16 > x_u32;
|
|
| ----- ^^^^^ expected `u16`, found `u32`
|
|
| |
|
|
| expected because this is `u16`
|
|
|
|
|
help: you can convert `x_u16` from `u16` to `u32`, matching the type of `x_u32`
|
|
|
|
|
LL | u32::from(x_u16) > x_u32;
|
|
| ++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:38:17
|
|
|
|
|
LL | x_u16 > x_u64;
|
|
| ----- ^^^^^ expected `u16`, found `u64`
|
|
| |
|
|
| expected because this is `u16`
|
|
|
|
|
help: you can convert `x_u16` from `u16` to `u64`, matching the type of `x_u64`
|
|
|
|
|
LL | u64::from(x_u16) > x_u64;
|
|
| ++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:40:17
|
|
|
|
|
LL | x_u16 > x_u128;
|
|
| ----- ^^^^^^ expected `u16`, found `u128`
|
|
| |
|
|
| expected because this is `u16`
|
|
|
|
|
help: you can convert `x_u16` from `u16` to `u128`, matching the type of `x_u128`
|
|
|
|
|
LL | u128::from(x_u16) > x_u128;
|
|
| +++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:42:17
|
|
|
|
|
LL | x_u16 > x_usize;
|
|
| ----- ^^^^^^^ expected `u16`, found `usize`
|
|
| |
|
|
| expected because this is `u16`
|
|
|
|
|
help: you can convert `x_u16` from `u16` to `usize`, matching the type of `x_usize`
|
|
|
|
|
LL | usize::from(x_u16) > x_usize;
|
|
| ++++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:45:17
|
|
|
|
|
LL | x_u32 > x_u8;
|
|
| ----- ^^^^ expected `u32`, found `u8`
|
|
| |
|
|
| expected because this is `u32`
|
|
|
|
|
help: you can convert a `u8` to a `u32`
|
|
|
|
|
LL | x_u32 > x_u8.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:47:17
|
|
|
|
|
LL | x_u32 > x_u16;
|
|
| ----- ^^^^^ expected `u32`, found `u16`
|
|
| |
|
|
| expected because this is `u32`
|
|
|
|
|
help: you can convert a `u16` to a `u32`
|
|
|
|
|
LL | x_u32 > x_u16.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:49:17
|
|
|
|
|
LL | x_u32 > x_u64;
|
|
| ----- ^^^^^ expected `u32`, found `u64`
|
|
| |
|
|
| expected because this is `u32`
|
|
|
|
|
help: you can convert `x_u32` from `u32` to `u64`, matching the type of `x_u64`
|
|
|
|
|
LL | u64::from(x_u32) > x_u64;
|
|
| ++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:51:17
|
|
|
|
|
LL | x_u32 > x_u128;
|
|
| ----- ^^^^^^ expected `u32`, found `u128`
|
|
| |
|
|
| expected because this is `u32`
|
|
|
|
|
help: you can convert `x_u32` from `u32` to `u128`, matching the type of `x_u128`
|
|
|
|
|
LL | u128::from(x_u32) > x_u128;
|
|
| +++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:53:17
|
|
|
|
|
LL | x_u32 > x_usize;
|
|
| ----- ^^^^^^^ expected `u32`, found `usize`
|
|
| |
|
|
| expected because this is `u32`
|
|
|
|
|
help: you can convert a `usize` to a `u32` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u32 > x_usize.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:56:17
|
|
|
|
|
LL | x_u64 > x_u8;
|
|
| ----- ^^^^ expected `u64`, found `u8`
|
|
| |
|
|
| expected because this is `u64`
|
|
|
|
|
help: you can convert a `u8` to a `u64`
|
|
|
|
|
LL | x_u64 > x_u8.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:58:17
|
|
|
|
|
LL | x_u64 > x_u16;
|
|
| ----- ^^^^^ expected `u64`, found `u16`
|
|
| |
|
|
| expected because this is `u64`
|
|
|
|
|
help: you can convert a `u16` to a `u64`
|
|
|
|
|
LL | x_u64 > x_u16.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:60:17
|
|
|
|
|
LL | x_u64 > x_u32;
|
|
| ----- ^^^^^ expected `u64`, found `u32`
|
|
| |
|
|
| expected because this is `u64`
|
|
|
|
|
help: you can convert a `u32` to a `u64`
|
|
|
|
|
LL | x_u64 > x_u32.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:62:17
|
|
|
|
|
LL | x_u64 > x_u128;
|
|
| ----- ^^^^^^ expected `u64`, found `u128`
|
|
| |
|
|
| expected because this is `u64`
|
|
|
|
|
help: you can convert `x_u64` from `u64` to `u128`, matching the type of `x_u128`
|
|
|
|
|
LL | u128::from(x_u64) > x_u128;
|
|
| +++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:64:17
|
|
|
|
|
LL | x_u64 > x_usize;
|
|
| ----- ^^^^^^^ expected `u64`, found `usize`
|
|
| |
|
|
| expected because this is `u64`
|
|
|
|
|
help: you can convert a `usize` to a `u64` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u64 > x_usize.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:67:18
|
|
|
|
|
LL | x_u128 > x_u8;
|
|
| ------ ^^^^ expected `u128`, found `u8`
|
|
| |
|
|
| expected because this is `u128`
|
|
|
|
|
help: you can convert a `u8` to a `u128`
|
|
|
|
|
LL | x_u128 > x_u8.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:69:18
|
|
|
|
|
LL | x_u128 > x_u16;
|
|
| ------ ^^^^^ expected `u128`, found `u16`
|
|
| |
|
|
| expected because this is `u128`
|
|
|
|
|
help: you can convert a `u16` to a `u128`
|
|
|
|
|
LL | x_u128 > x_u16.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:71:18
|
|
|
|
|
LL | x_u128 > x_u32;
|
|
| ------ ^^^^^ expected `u128`, found `u32`
|
|
| |
|
|
| expected because this is `u128`
|
|
|
|
|
help: you can convert a `u32` to a `u128`
|
|
|
|
|
LL | x_u128 > x_u32.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:73:18
|
|
|
|
|
LL | x_u128 > x_u64;
|
|
| ------ ^^^^^ expected `u128`, found `u64`
|
|
| |
|
|
| expected because this is `u128`
|
|
|
|
|
help: you can convert a `u64` to a `u128`
|
|
|
|
|
LL | x_u128 > x_u64.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:75:18
|
|
|
|
|
LL | x_u128 > x_usize;
|
|
| ------ ^^^^^^^ expected `u128`, found `usize`
|
|
| |
|
|
| expected because this is `u128`
|
|
|
|
|
help: you can convert a `usize` to a `u128` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u128 > x_usize.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:78:19
|
|
|
|
|
LL | x_usize > x_u8;
|
|
| ------- ^^^^ expected `usize`, found `u8`
|
|
| |
|
|
| expected because this is `usize`
|
|
|
|
|
help: you can convert a `u8` to a `usize`
|
|
|
|
|
LL | x_usize > x_u8.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:80:19
|
|
|
|
|
LL | x_usize > x_u16;
|
|
| ------- ^^^^^ expected `usize`, found `u16`
|
|
| |
|
|
| expected because this is `usize`
|
|
|
|
|
help: you can convert a `u16` to a `usize`
|
|
|
|
|
LL | x_usize > x_u16.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:82:19
|
|
|
|
|
LL | x_usize > x_u32;
|
|
| ------- ^^^^^ expected `usize`, found `u32`
|
|
| |
|
|
| expected because this is `usize`
|
|
|
|
|
help: you can convert a `u32` to a `usize` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_usize > x_u32.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:84:19
|
|
|
|
|
LL | x_usize > x_u64;
|
|
| ------- ^^^^^ expected `usize`, found `u64`
|
|
| |
|
|
| expected because this is `usize`
|
|
|
|
|
help: you can convert a `u64` to a `usize` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_usize > x_u64.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:86:19
|
|
|
|
|
LL | x_usize > x_u128;
|
|
| ------- ^^^^^^ expected `usize`, found `u128`
|
|
| |
|
|
| expected because this is `usize`
|
|
|
|
|
help: you can convert a `u128` to a `usize` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_usize > x_u128.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:92:16
|
|
|
|
|
LL | x_i8 > x_i16;
|
|
| ---- ^^^^^ expected `i8`, found `i16`
|
|
| |
|
|
| expected because this is `i8`
|
|
|
|
|
help: you can convert `x_i8` from `i8` to `i16`, matching the type of `x_i16`
|
|
|
|
|
LL | i16::from(x_i8) > x_i16;
|
|
| ++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:94:16
|
|
|
|
|
LL | x_i8 > x_i32;
|
|
| ---- ^^^^^ expected `i8`, found `i32`
|
|
| |
|
|
| expected because this is `i8`
|
|
|
|
|
help: you can convert `x_i8` from `i8` to `i32`, matching the type of `x_i32`
|
|
|
|
|
LL | i32::from(x_i8) > x_i32;
|
|
| ++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:96:16
|
|
|
|
|
LL | x_i8 > x_i64;
|
|
| ---- ^^^^^ expected `i8`, found `i64`
|
|
| |
|
|
| expected because this is `i8`
|
|
|
|
|
help: you can convert `x_i8` from `i8` to `i64`, matching the type of `x_i64`
|
|
|
|
|
LL | i64::from(x_i8) > x_i64;
|
|
| ++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:98:16
|
|
|
|
|
LL | x_i8 > x_i128;
|
|
| ---- ^^^^^^ expected `i8`, found `i128`
|
|
| |
|
|
| expected because this is `i8`
|
|
|
|
|
help: you can convert `x_i8` from `i8` to `i128`, matching the type of `x_i128`
|
|
|
|
|
LL | i128::from(x_i8) > x_i128;
|
|
| +++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:100:16
|
|
|
|
|
LL | x_i8 > x_isize;
|
|
| ---- ^^^^^^^ expected `i8`, found `isize`
|
|
| |
|
|
| expected because this is `i8`
|
|
|
|
|
help: you can convert `x_i8` from `i8` to `isize`, matching the type of `x_isize`
|
|
|
|
|
LL | isize::from(x_i8) > x_isize;
|
|
| ++++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:103:17
|
|
|
|
|
LL | x_i16 > x_i8;
|
|
| ----- ^^^^ expected `i16`, found `i8`
|
|
| |
|
|
| expected because this is `i16`
|
|
|
|
|
help: you can convert an `i8` to an `i16`
|
|
|
|
|
LL | x_i16 > x_i8.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:105:17
|
|
|
|
|
LL | x_i16 > x_i32;
|
|
| ----- ^^^^^ expected `i16`, found `i32`
|
|
| |
|
|
| expected because this is `i16`
|
|
|
|
|
help: you can convert `x_i16` from `i16` to `i32`, matching the type of `x_i32`
|
|
|
|
|
LL | i32::from(x_i16) > x_i32;
|
|
| ++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:107:17
|
|
|
|
|
LL | x_i16 > x_i64;
|
|
| ----- ^^^^^ expected `i16`, found `i64`
|
|
| |
|
|
| expected because this is `i16`
|
|
|
|
|
help: you can convert `x_i16` from `i16` to `i64`, matching the type of `x_i64`
|
|
|
|
|
LL | i64::from(x_i16) > x_i64;
|
|
| ++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:109:17
|
|
|
|
|
LL | x_i16 > x_i128;
|
|
| ----- ^^^^^^ expected `i16`, found `i128`
|
|
| |
|
|
| expected because this is `i16`
|
|
|
|
|
help: you can convert `x_i16` from `i16` to `i128`, matching the type of `x_i128`
|
|
|
|
|
LL | i128::from(x_i16) > x_i128;
|
|
| +++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:111:17
|
|
|
|
|
LL | x_i16 > x_isize;
|
|
| ----- ^^^^^^^ expected `i16`, found `isize`
|
|
| |
|
|
| expected because this is `i16`
|
|
|
|
|
help: you can convert `x_i16` from `i16` to `isize`, matching the type of `x_isize`
|
|
|
|
|
LL | isize::from(x_i16) > x_isize;
|
|
| ++++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:114:17
|
|
|
|
|
LL | x_i32 > x_i8;
|
|
| ----- ^^^^ expected `i32`, found `i8`
|
|
| |
|
|
| expected because this is `i32`
|
|
|
|
|
help: you can convert an `i8` to an `i32`
|
|
|
|
|
LL | x_i32 > x_i8.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:116:17
|
|
|
|
|
LL | x_i32 > x_i16;
|
|
| ----- ^^^^^ expected `i32`, found `i16`
|
|
| |
|
|
| expected because this is `i32`
|
|
|
|
|
help: you can convert an `i16` to an `i32`
|
|
|
|
|
LL | x_i32 > x_i16.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:118:17
|
|
|
|
|
LL | x_i32 > x_i64;
|
|
| ----- ^^^^^ expected `i32`, found `i64`
|
|
| |
|
|
| expected because this is `i32`
|
|
|
|
|
help: you can convert `x_i32` from `i32` to `i64`, matching the type of `x_i64`
|
|
|
|
|
LL | i64::from(x_i32) > x_i64;
|
|
| ++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:120:17
|
|
|
|
|
LL | x_i32 > x_i128;
|
|
| ----- ^^^^^^ expected `i32`, found `i128`
|
|
| |
|
|
| expected because this is `i32`
|
|
|
|
|
help: you can convert `x_i32` from `i32` to `i128`, matching the type of `x_i128`
|
|
|
|
|
LL | i128::from(x_i32) > x_i128;
|
|
| +++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:122:17
|
|
|
|
|
LL | x_i32 > x_isize;
|
|
| ----- ^^^^^^^ expected `i32`, found `isize`
|
|
| |
|
|
| expected because this is `i32`
|
|
|
|
|
help: you can convert an `isize` to an `i32` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i32 > x_isize.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:125:17
|
|
|
|
|
LL | x_i64 > x_i8;
|
|
| ----- ^^^^ expected `i64`, found `i8`
|
|
| |
|
|
| expected because this is `i64`
|
|
|
|
|
help: you can convert an `i8` to an `i64`
|
|
|
|
|
LL | x_i64 > x_i8.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:127:17
|
|
|
|
|
LL | x_i64 > x_i16;
|
|
| ----- ^^^^^ expected `i64`, found `i16`
|
|
| |
|
|
| expected because this is `i64`
|
|
|
|
|
help: you can convert an `i16` to an `i64`
|
|
|
|
|
LL | x_i64 > x_i16.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:129:17
|
|
|
|
|
LL | x_i64 > x_i32;
|
|
| ----- ^^^^^ expected `i64`, found `i32`
|
|
| |
|
|
| expected because this is `i64`
|
|
|
|
|
help: you can convert an `i32` to an `i64`
|
|
|
|
|
LL | x_i64 > x_i32.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:131:17
|
|
|
|
|
LL | x_i64 > x_i128;
|
|
| ----- ^^^^^^ expected `i64`, found `i128`
|
|
| |
|
|
| expected because this is `i64`
|
|
|
|
|
help: you can convert `x_i64` from `i64` to `i128`, matching the type of `x_i128`
|
|
|
|
|
LL | i128::from(x_i64) > x_i128;
|
|
| +++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:133:17
|
|
|
|
|
LL | x_i64 > x_isize;
|
|
| ----- ^^^^^^^ expected `i64`, found `isize`
|
|
| |
|
|
| expected because this is `i64`
|
|
|
|
|
help: you can convert an `isize` to an `i64` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i64 > x_isize.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:136:18
|
|
|
|
|
LL | x_i128 > x_i8;
|
|
| ------ ^^^^ expected `i128`, found `i8`
|
|
| |
|
|
| expected because this is `i128`
|
|
|
|
|
help: you can convert an `i8` to an `i128`
|
|
|
|
|
LL | x_i128 > x_i8.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:138:18
|
|
|
|
|
LL | x_i128 > x_i16;
|
|
| ------ ^^^^^ expected `i128`, found `i16`
|
|
| |
|
|
| expected because this is `i128`
|
|
|
|
|
help: you can convert an `i16` to an `i128`
|
|
|
|
|
LL | x_i128 > x_i16.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:140:18
|
|
|
|
|
LL | x_i128 > x_i32;
|
|
| ------ ^^^^^ expected `i128`, found `i32`
|
|
| |
|
|
| expected because this is `i128`
|
|
|
|
|
help: you can convert an `i32` to an `i128`
|
|
|
|
|
LL | x_i128 > x_i32.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:142:18
|
|
|
|
|
LL | x_i128 > x_i64;
|
|
| ------ ^^^^^ expected `i128`, found `i64`
|
|
| |
|
|
| expected because this is `i128`
|
|
|
|
|
help: you can convert an `i64` to an `i128`
|
|
|
|
|
LL | x_i128 > x_i64.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:144:18
|
|
|
|
|
LL | x_i128 > x_isize;
|
|
| ------ ^^^^^^^ expected `i128`, found `isize`
|
|
| |
|
|
| expected because this is `i128`
|
|
|
|
|
help: you can convert an `isize` to an `i128` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i128 > x_isize.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:147:19
|
|
|
|
|
LL | x_isize > x_i8;
|
|
| ------- ^^^^ expected `isize`, found `i8`
|
|
| |
|
|
| expected because this is `isize`
|
|
|
|
|
help: you can convert an `i8` to an `isize`
|
|
|
|
|
LL | x_isize > x_i8.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:149:19
|
|
|
|
|
LL | x_isize > x_i16;
|
|
| ------- ^^^^^ expected `isize`, found `i16`
|
|
| |
|
|
| expected because this is `isize`
|
|
|
|
|
help: you can convert an `i16` to an `isize`
|
|
|
|
|
LL | x_isize > x_i16.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:151:19
|
|
|
|
|
LL | x_isize > x_i32;
|
|
| ------- ^^^^^ expected `isize`, found `i32`
|
|
| |
|
|
| expected because this is `isize`
|
|
|
|
|
help: you can convert an `i32` to an `isize` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_isize > x_i32.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:153:19
|
|
|
|
|
LL | x_isize > x_i64;
|
|
| ------- ^^^^^ expected `isize`, found `i64`
|
|
| |
|
|
| expected because this is `isize`
|
|
|
|
|
help: you can convert an `i64` to an `isize` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_isize > x_i64.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:155:19
|
|
|
|
|
LL | x_isize > x_i128;
|
|
| ------- ^^^^^^ expected `isize`, found `i128`
|
|
| |
|
|
| expected because this is `isize`
|
|
|
|
|
help: you can convert an `i128` to an `isize` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_isize > x_i128.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:161:16
|
|
|
|
|
LL | x_u8 > x_i8;
|
|
| ---- ^^^^ expected `u8`, found `i8`
|
|
| |
|
|
| expected because this is `u8`
|
|
|
|
|
help: you can convert an `i8` to a `u8` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u8 > x_i8.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:163:16
|
|
|
|
|
LL | x_u8 > x_i16;
|
|
| ---- ^^^^^ expected `u8`, found `i16`
|
|
| |
|
|
| expected because this is `u8`
|
|
|
|
|
help: you can convert `x_u8` from `u8` to `i16`, matching the type of `x_i16`
|
|
|
|
|
LL | i16::from(x_u8) > x_i16;
|
|
| ++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:165:16
|
|
|
|
|
LL | x_u8 > x_i32;
|
|
| ---- ^^^^^ expected `u8`, found `i32`
|
|
| |
|
|
| expected because this is `u8`
|
|
|
|
|
help: you can convert `x_u8` from `u8` to `i32`, matching the type of `x_i32`
|
|
|
|
|
LL | i32::from(x_u8) > x_i32;
|
|
| ++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:167:16
|
|
|
|
|
LL | x_u8 > x_i64;
|
|
| ---- ^^^^^ expected `u8`, found `i64`
|
|
| |
|
|
| expected because this is `u8`
|
|
|
|
|
help: you can convert `x_u8` from `u8` to `i64`, matching the type of `x_i64`
|
|
|
|
|
LL | i64::from(x_u8) > x_i64;
|
|
| ++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:169:16
|
|
|
|
|
LL | x_u8 > x_i128;
|
|
| ---- ^^^^^^ expected `u8`, found `i128`
|
|
| |
|
|
| expected because this is `u8`
|
|
|
|
|
help: you can convert `x_u8` from `u8` to `i128`, matching the type of `x_i128`
|
|
|
|
|
LL | i128::from(x_u8) > x_i128;
|
|
| +++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:171:16
|
|
|
|
|
LL | x_u8 > x_isize;
|
|
| ---- ^^^^^^^ expected `u8`, found `isize`
|
|
| |
|
|
| expected because this is `u8`
|
|
|
|
|
help: you can convert `x_u8` from `u8` to `isize`, matching the type of `x_isize`
|
|
|
|
|
LL | isize::from(x_u8) > x_isize;
|
|
| ++++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:174:17
|
|
|
|
|
LL | x_u16 > x_i8;
|
|
| ----- ^^^^ expected `u16`, found `i8`
|
|
| |
|
|
| expected because this is `u16`
|
|
|
|
|
help: you can convert an `i8` to a `u16` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u16 > x_i8.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:176:17
|
|
|
|
|
LL | x_u16 > x_i16;
|
|
| ----- ^^^^^ expected `u16`, found `i16`
|
|
| |
|
|
| expected because this is `u16`
|
|
|
|
|
help: you can convert an `i16` to a `u16` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u16 > x_i16.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:178:17
|
|
|
|
|
LL | x_u16 > x_i32;
|
|
| ----- ^^^^^ expected `u16`, found `i32`
|
|
| |
|
|
| expected because this is `u16`
|
|
|
|
|
help: you can convert `x_u16` from `u16` to `i32`, matching the type of `x_i32`
|
|
|
|
|
LL | i32::from(x_u16) > x_i32;
|
|
| ++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:180:17
|
|
|
|
|
LL | x_u16 > x_i64;
|
|
| ----- ^^^^^ expected `u16`, found `i64`
|
|
| |
|
|
| expected because this is `u16`
|
|
|
|
|
help: you can convert `x_u16` from `u16` to `i64`, matching the type of `x_i64`
|
|
|
|
|
LL | i64::from(x_u16) > x_i64;
|
|
| ++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:182:17
|
|
|
|
|
LL | x_u16 > x_i128;
|
|
| ----- ^^^^^^ expected `u16`, found `i128`
|
|
| |
|
|
| expected because this is `u16`
|
|
|
|
|
help: you can convert `x_u16` from `u16` to `i128`, matching the type of `x_i128`
|
|
|
|
|
LL | i128::from(x_u16) > x_i128;
|
|
| +++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:184:17
|
|
|
|
|
LL | x_u16 > x_isize;
|
|
| ----- ^^^^^^^ expected `u16`, found `isize`
|
|
| |
|
|
| expected because this is `u16`
|
|
|
|
|
help: you can convert an `isize` to a `u16` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u16 > x_isize.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:187:17
|
|
|
|
|
LL | x_u32 > x_i8;
|
|
| ----- ^^^^ expected `u32`, found `i8`
|
|
| |
|
|
| expected because this is `u32`
|
|
|
|
|
help: you can convert an `i8` to a `u32` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u32 > x_i8.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:189:17
|
|
|
|
|
LL | x_u32 > x_i16;
|
|
| ----- ^^^^^ expected `u32`, found `i16`
|
|
| |
|
|
| expected because this is `u32`
|
|
|
|
|
help: you can convert an `i16` to a `u32` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u32 > x_i16.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:191:17
|
|
|
|
|
LL | x_u32 > x_i32;
|
|
| ----- ^^^^^ expected `u32`, found `i32`
|
|
| |
|
|
| expected because this is `u32`
|
|
|
|
|
help: you can convert an `i32` to a `u32` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u32 > x_i32.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:193:17
|
|
|
|
|
LL | x_u32 > x_i64;
|
|
| ----- ^^^^^ expected `u32`, found `i64`
|
|
| |
|
|
| expected because this is `u32`
|
|
|
|
|
help: you can convert `x_u32` from `u32` to `i64`, matching the type of `x_i64`
|
|
|
|
|
LL | i64::from(x_u32) > x_i64;
|
|
| ++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:195:17
|
|
|
|
|
LL | x_u32 > x_i128;
|
|
| ----- ^^^^^^ expected `u32`, found `i128`
|
|
| |
|
|
| expected because this is `u32`
|
|
|
|
|
help: you can convert `x_u32` from `u32` to `i128`, matching the type of `x_i128`
|
|
|
|
|
LL | i128::from(x_u32) > x_i128;
|
|
| +++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:197:17
|
|
|
|
|
LL | x_u32 > x_isize;
|
|
| ----- ^^^^^^^ expected `u32`, found `isize`
|
|
| |
|
|
| expected because this is `u32`
|
|
|
|
|
help: you can convert an `isize` to a `u32` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u32 > x_isize.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:200:17
|
|
|
|
|
LL | x_u64 > x_i8;
|
|
| ----- ^^^^ expected `u64`, found `i8`
|
|
| |
|
|
| expected because this is `u64`
|
|
|
|
|
help: you can convert an `i8` to a `u64` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u64 > x_i8.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:202:17
|
|
|
|
|
LL | x_u64 > x_i16;
|
|
| ----- ^^^^^ expected `u64`, found `i16`
|
|
| |
|
|
| expected because this is `u64`
|
|
|
|
|
help: you can convert an `i16` to a `u64` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u64 > x_i16.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:204:17
|
|
|
|
|
LL | x_u64 > x_i32;
|
|
| ----- ^^^^^ expected `u64`, found `i32`
|
|
| |
|
|
| expected because this is `u64`
|
|
|
|
|
help: you can convert an `i32` to a `u64` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u64 > x_i32.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:206:17
|
|
|
|
|
LL | x_u64 > x_i64;
|
|
| ----- ^^^^^ expected `u64`, found `i64`
|
|
| |
|
|
| expected because this is `u64`
|
|
|
|
|
help: you can convert an `i64` to a `u64` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u64 > x_i64.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:208:17
|
|
|
|
|
LL | x_u64 > x_i128;
|
|
| ----- ^^^^^^ expected `u64`, found `i128`
|
|
| |
|
|
| expected because this is `u64`
|
|
|
|
|
help: you can convert `x_u64` from `u64` to `i128`, matching the type of `x_i128`
|
|
|
|
|
LL | i128::from(x_u64) > x_i128;
|
|
| +++++++++++ +
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:210:17
|
|
|
|
|
LL | x_u64 > x_isize;
|
|
| ----- ^^^^^^^ expected `u64`, found `isize`
|
|
| |
|
|
| expected because this is `u64`
|
|
|
|
|
help: you can convert an `isize` to a `u64` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u64 > x_isize.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:213:18
|
|
|
|
|
LL | x_u128 > x_i8;
|
|
| ------ ^^^^ expected `u128`, found `i8`
|
|
| |
|
|
| expected because this is `u128`
|
|
|
|
|
help: you can convert an `i8` to a `u128` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u128 > x_i8.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:215:18
|
|
|
|
|
LL | x_u128 > x_i16;
|
|
| ------ ^^^^^ expected `u128`, found `i16`
|
|
| |
|
|
| expected because this is `u128`
|
|
|
|
|
help: you can convert an `i16` to a `u128` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u128 > x_i16.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:217:18
|
|
|
|
|
LL | x_u128 > x_i32;
|
|
| ------ ^^^^^ expected `u128`, found `i32`
|
|
| |
|
|
| expected because this is `u128`
|
|
|
|
|
help: you can convert an `i32` to a `u128` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u128 > x_i32.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:219:18
|
|
|
|
|
LL | x_u128 > x_i64;
|
|
| ------ ^^^^^ expected `u128`, found `i64`
|
|
| |
|
|
| expected because this is `u128`
|
|
|
|
|
help: you can convert an `i64` to a `u128` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u128 > x_i64.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:221:18
|
|
|
|
|
LL | x_u128 > x_i128;
|
|
| ------ ^^^^^^ expected `u128`, found `i128`
|
|
| |
|
|
| expected because this is `u128`
|
|
|
|
|
help: you can convert an `i128` to a `u128` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u128 > x_i128.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:223:18
|
|
|
|
|
LL | x_u128 > x_isize;
|
|
| ------ ^^^^^^^ expected `u128`, found `isize`
|
|
| |
|
|
| expected because this is `u128`
|
|
|
|
|
help: you can convert an `isize` to a `u128` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_u128 > x_isize.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:226:19
|
|
|
|
|
LL | x_usize > x_i8;
|
|
| ------- ^^^^ expected `usize`, found `i8`
|
|
| |
|
|
| expected because this is `usize`
|
|
|
|
|
help: you can convert an `i8` to a `usize` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_usize > x_i8.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:228:19
|
|
|
|
|
LL | x_usize > x_i16;
|
|
| ------- ^^^^^ expected `usize`, found `i16`
|
|
| |
|
|
| expected because this is `usize`
|
|
|
|
|
help: you can convert an `i16` to a `usize` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_usize > x_i16.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:230:19
|
|
|
|
|
LL | x_usize > x_i32;
|
|
| ------- ^^^^^ expected `usize`, found `i32`
|
|
| |
|
|
| expected because this is `usize`
|
|
|
|
|
help: you can convert an `i32` to a `usize` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_usize > x_i32.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:232:19
|
|
|
|
|
LL | x_usize > x_i64;
|
|
| ------- ^^^^^ expected `usize`, found `i64`
|
|
| |
|
|
| expected because this is `usize`
|
|
|
|
|
help: you can convert an `i64` to a `usize` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_usize > x_i64.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:234:19
|
|
|
|
|
LL | x_usize > x_i128;
|
|
| ------- ^^^^^^ expected `usize`, found `i128`
|
|
| |
|
|
| expected because this is `usize`
|
|
|
|
|
help: you can convert an `i128` to a `usize` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_usize > x_i128.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:236:19
|
|
|
|
|
LL | x_usize > x_isize;
|
|
| ------- ^^^^^^^ expected `usize`, found `isize`
|
|
| |
|
|
| expected because this is `usize`
|
|
|
|
|
help: you can convert an `isize` to a `usize` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_usize > x_isize.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:242:16
|
|
|
|
|
LL | x_i8 > x_u8;
|
|
| ---- ^^^^ expected `i8`, found `u8`
|
|
| |
|
|
| expected because this is `i8`
|
|
|
|
|
help: you can convert a `u8` to an `i8` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i8 > x_u8.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:244:16
|
|
|
|
|
LL | x_i8 > x_u16;
|
|
| ---- ^^^^^ expected `i8`, found `u16`
|
|
| |
|
|
| expected because this is `i8`
|
|
|
|
|
help: you can convert a `u16` to an `i8` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i8 > x_u16.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:246:16
|
|
|
|
|
LL | x_i8 > x_u32;
|
|
| ---- ^^^^^ expected `i8`, found `u32`
|
|
| |
|
|
| expected because this is `i8`
|
|
|
|
|
help: you can convert a `u32` to an `i8` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i8 > x_u32.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:248:16
|
|
|
|
|
LL | x_i8 > x_u64;
|
|
| ---- ^^^^^ expected `i8`, found `u64`
|
|
| |
|
|
| expected because this is `i8`
|
|
|
|
|
help: you can convert a `u64` to an `i8` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i8 > x_u64.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:250:16
|
|
|
|
|
LL | x_i8 > x_u128;
|
|
| ---- ^^^^^^ expected `i8`, found `u128`
|
|
| |
|
|
| expected because this is `i8`
|
|
|
|
|
help: you can convert a `u128` to an `i8` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i8 > x_u128.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:252:16
|
|
|
|
|
LL | x_i8 > x_usize;
|
|
| ---- ^^^^^^^ expected `i8`, found `usize`
|
|
| |
|
|
| expected because this is `i8`
|
|
|
|
|
help: you can convert a `usize` to an `i8` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i8 > x_usize.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:255:17
|
|
|
|
|
LL | x_i16 > x_u8;
|
|
| ----- ^^^^ expected `i16`, found `u8`
|
|
| |
|
|
| expected because this is `i16`
|
|
|
|
|
help: you can convert a `u8` to an `i16`
|
|
|
|
|
LL | x_i16 > x_u8.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:257:17
|
|
|
|
|
LL | x_i16 > x_u16;
|
|
| ----- ^^^^^ expected `i16`, found `u16`
|
|
| |
|
|
| expected because this is `i16`
|
|
|
|
|
help: you can convert a `u16` to an `i16` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i16 > x_u16.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:259:17
|
|
|
|
|
LL | x_i16 > x_u32;
|
|
| ----- ^^^^^ expected `i16`, found `u32`
|
|
| |
|
|
| expected because this is `i16`
|
|
|
|
|
help: you can convert a `u32` to an `i16` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i16 > x_u32.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:261:17
|
|
|
|
|
LL | x_i16 > x_u64;
|
|
| ----- ^^^^^ expected `i16`, found `u64`
|
|
| |
|
|
| expected because this is `i16`
|
|
|
|
|
help: you can convert a `u64` to an `i16` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i16 > x_u64.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:263:17
|
|
|
|
|
LL | x_i16 > x_u128;
|
|
| ----- ^^^^^^ expected `i16`, found `u128`
|
|
| |
|
|
| expected because this is `i16`
|
|
|
|
|
help: you can convert a `u128` to an `i16` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i16 > x_u128.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:265:17
|
|
|
|
|
LL | x_i16 > x_usize;
|
|
| ----- ^^^^^^^ expected `i16`, found `usize`
|
|
| |
|
|
| expected because this is `i16`
|
|
|
|
|
help: you can convert a `usize` to an `i16` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i16 > x_usize.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:268:17
|
|
|
|
|
LL | x_i32 > x_u8;
|
|
| ----- ^^^^ expected `i32`, found `u8`
|
|
| |
|
|
| expected because this is `i32`
|
|
|
|
|
help: you can convert a `u8` to an `i32`
|
|
|
|
|
LL | x_i32 > x_u8.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:270:17
|
|
|
|
|
LL | x_i32 > x_u16;
|
|
| ----- ^^^^^ expected `i32`, found `u16`
|
|
| |
|
|
| expected because this is `i32`
|
|
|
|
|
help: you can convert a `u16` to an `i32`
|
|
|
|
|
LL | x_i32 > x_u16.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:272:17
|
|
|
|
|
LL | x_i32 > x_u32;
|
|
| ----- ^^^^^ expected `i32`, found `u32`
|
|
| |
|
|
| expected because this is `i32`
|
|
|
|
|
help: you can convert a `u32` to an `i32` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i32 > x_u32.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:274:17
|
|
|
|
|
LL | x_i32 > x_u64;
|
|
| ----- ^^^^^ expected `i32`, found `u64`
|
|
| |
|
|
| expected because this is `i32`
|
|
|
|
|
help: you can convert a `u64` to an `i32` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i32 > x_u64.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:276:17
|
|
|
|
|
LL | x_i32 > x_u128;
|
|
| ----- ^^^^^^ expected `i32`, found `u128`
|
|
| |
|
|
| expected because this is `i32`
|
|
|
|
|
help: you can convert a `u128` to an `i32` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i32 > x_u128.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:278:17
|
|
|
|
|
LL | x_i32 > x_usize;
|
|
| ----- ^^^^^^^ expected `i32`, found `usize`
|
|
| |
|
|
| expected because this is `i32`
|
|
|
|
|
help: you can convert a `usize` to an `i32` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i32 > x_usize.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:281:17
|
|
|
|
|
LL | x_i64 > x_u8;
|
|
| ----- ^^^^ expected `i64`, found `u8`
|
|
| |
|
|
| expected because this is `i64`
|
|
|
|
|
help: you can convert a `u8` to an `i64`
|
|
|
|
|
LL | x_i64 > x_u8.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:283:17
|
|
|
|
|
LL | x_i64 > x_u16;
|
|
| ----- ^^^^^ expected `i64`, found `u16`
|
|
| |
|
|
| expected because this is `i64`
|
|
|
|
|
help: you can convert a `u16` to an `i64`
|
|
|
|
|
LL | x_i64 > x_u16.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:285:17
|
|
|
|
|
LL | x_i64 > x_u32;
|
|
| ----- ^^^^^ expected `i64`, found `u32`
|
|
| |
|
|
| expected because this is `i64`
|
|
|
|
|
help: you can convert a `u32` to an `i64`
|
|
|
|
|
LL | x_i64 > x_u32.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:287:17
|
|
|
|
|
LL | x_i64 > x_u64;
|
|
| ----- ^^^^^ expected `i64`, found `u64`
|
|
| |
|
|
| expected because this is `i64`
|
|
|
|
|
help: you can convert a `u64` to an `i64` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i64 > x_u64.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:289:17
|
|
|
|
|
LL | x_i64 > x_u128;
|
|
| ----- ^^^^^^ expected `i64`, found `u128`
|
|
| |
|
|
| expected because this is `i64`
|
|
|
|
|
help: you can convert a `u128` to an `i64` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i64 > x_u128.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:291:17
|
|
|
|
|
LL | x_i64 > x_usize;
|
|
| ----- ^^^^^^^ expected `i64`, found `usize`
|
|
| |
|
|
| expected because this is `i64`
|
|
|
|
|
help: you can convert a `usize` to an `i64` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i64 > x_usize.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:294:18
|
|
|
|
|
LL | x_i128 > x_u8;
|
|
| ------ ^^^^ expected `i128`, found `u8`
|
|
| |
|
|
| expected because this is `i128`
|
|
|
|
|
help: you can convert a `u8` to an `i128`
|
|
|
|
|
LL | x_i128 > x_u8.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:296:18
|
|
|
|
|
LL | x_i128 > x_u16;
|
|
| ------ ^^^^^ expected `i128`, found `u16`
|
|
| |
|
|
| expected because this is `i128`
|
|
|
|
|
help: you can convert a `u16` to an `i128`
|
|
|
|
|
LL | x_i128 > x_u16.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:298:18
|
|
|
|
|
LL | x_i128 > x_u32;
|
|
| ------ ^^^^^ expected `i128`, found `u32`
|
|
| |
|
|
| expected because this is `i128`
|
|
|
|
|
help: you can convert a `u32` to an `i128`
|
|
|
|
|
LL | x_i128 > x_u32.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:300:18
|
|
|
|
|
LL | x_i128 > x_u64;
|
|
| ------ ^^^^^ expected `i128`, found `u64`
|
|
| |
|
|
| expected because this is `i128`
|
|
|
|
|
help: you can convert a `u64` to an `i128`
|
|
|
|
|
LL | x_i128 > x_u64.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:302:18
|
|
|
|
|
LL | x_i128 > x_u128;
|
|
| ------ ^^^^^^ expected `i128`, found `u128`
|
|
| |
|
|
| expected because this is `i128`
|
|
|
|
|
help: you can convert a `u128` to an `i128` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i128 > x_u128.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:304:18
|
|
|
|
|
LL | x_i128 > x_usize;
|
|
| ------ ^^^^^^^ expected `i128`, found `usize`
|
|
| |
|
|
| expected because this is `i128`
|
|
|
|
|
help: you can convert a `usize` to an `i128` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_i128 > x_usize.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:307:19
|
|
|
|
|
LL | x_isize > x_u8;
|
|
| ------- ^^^^ expected `isize`, found `u8`
|
|
| |
|
|
| expected because this is `isize`
|
|
|
|
|
help: you can convert a `u8` to an `isize`
|
|
|
|
|
LL | x_isize > x_u8.into();
|
|
| +++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:309:19
|
|
|
|
|
LL | x_isize > x_u16;
|
|
| ------- ^^^^^ expected `isize`, found `u16`
|
|
| |
|
|
| expected because this is `isize`
|
|
|
|
|
help: you can convert a `u16` to an `isize` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_isize > x_u16.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:311:19
|
|
|
|
|
LL | x_isize > x_u32;
|
|
| ------- ^^^^^ expected `isize`, found `u32`
|
|
| |
|
|
| expected because this is `isize`
|
|
|
|
|
help: you can convert a `u32` to an `isize` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_isize > x_u32.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:313:19
|
|
|
|
|
LL | x_isize > x_u64;
|
|
| ------- ^^^^^ expected `isize`, found `u64`
|
|
| |
|
|
| expected because this is `isize`
|
|
|
|
|
help: you can convert a `u64` to an `isize` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_isize > x_u64.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:315:19
|
|
|
|
|
LL | x_isize > x_u128;
|
|
| ------- ^^^^^^ expected `isize`, found `u128`
|
|
| |
|
|
| expected because this is `isize`
|
|
|
|
|
help: you can convert a `u128` to an `isize` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_isize > x_u128.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/numeric-cast-binop.rs:317:19
|
|
|
|
|
LL | x_isize > x_usize;
|
|
| ------- ^^^^^^^ expected `isize`, found `usize`
|
|
| |
|
|
| expected because this is `isize`
|
|
|
|
|
help: you can convert a `usize` to an `isize` and panic if the converted value doesn't fit
|
|
|
|
|
LL | x_isize > x_usize.try_into().unwrap();
|
|
| ++++++++++++++++++++
|
|
|
|
error: aborting due to 132 previous errors
|
|
|
|
For more information about this error, try `rustc --explain E0308`.
|