2020-09-10 19:43:53 +02:00
|
|
|
error[E0308]: mismatched types
|
2022-09-15 11:29:12 +10:00
|
|
|
--> $DIR/issue-73260.rs:15:12
|
2020-09-10 19:43:53 +02:00
|
|
|
|
|
2020-10-24 19:21:40 -04:00
|
|
|
LL | let x: Arr<{usize::MAX}> = Arr {};
|
|
|
|
| ^^^^^^^^^^^^^^^^^ expected `false`, found `true`
|
2020-09-10 19:43:53 +02:00
|
|
|
|
|
2022-08-12 02:00:37 +00:00
|
|
|
= note: expected constant `false`
|
|
|
|
found constant `true`
|
2022-08-12 03:13:45 +00:00
|
|
|
note: required by a bound in `Arr`
|
2022-09-15 11:29:12 +10:00
|
|
|
--> $DIR/issue-73260.rs:5:37
|
2022-08-12 03:13:45 +00:00
|
|
|
|
|
|
|
|
LL | struct Arr<const N: usize>
|
2023-02-21 05:21:07 +00:00
|
|
|
| --- required by a bound in this struct
|
2022-08-12 03:13:45 +00:00
|
|
|
LL | where
|
|
|
|
LL | Assert::<{N < usize::MAX / 2}>: IsTrue,
|
|
|
|
| ^^^^^^ required by this bound in `Arr`
|
2020-09-10 19:43:53 +02:00
|
|
|
|
|
|
|
error[E0308]: mismatched types
|
2022-09-15 11:29:12 +10:00
|
|
|
--> $DIR/issue-73260.rs:15:32
|
2020-09-10 19:43:53 +02:00
|
|
|
|
|
2020-10-24 19:21:40 -04:00
|
|
|
LL | let x: Arr<{usize::MAX}> = Arr {};
|
|
|
|
| ^^^ expected `false`, found `true`
|
2020-09-10 19:43:53 +02:00
|
|
|
|
|
2022-08-12 02:00:37 +00:00
|
|
|
= note: expected constant `false`
|
|
|
|
found constant `true`
|
2022-08-12 03:13:45 +00:00
|
|
|
note: required by a bound in `Arr`
|
2022-09-15 11:29:12 +10:00
|
|
|
--> $DIR/issue-73260.rs:5:37
|
2022-08-12 03:13:45 +00:00
|
|
|
|
|
|
|
|
LL | struct Arr<const N: usize>
|
2023-02-21 05:21:07 +00:00
|
|
|
| --- required by a bound in this struct
|
2022-08-12 03:13:45 +00:00
|
|
|
LL | where
|
|
|
|
LL | Assert::<{N < usize::MAX / 2}>: IsTrue,
|
|
|
|
| ^^^^^^ required by this bound in `Arr`
|
2020-09-10 19:43:53 +02:00
|
|
|
|
2021-08-27 18:04:57 +02:00
|
|
|
error: aborting due to 2 previous errors
|
2020-09-10 19:43:53 +02:00
|
|
|
|
|
|
|
For more information about this error, try `rustc --explain E0308`.
|