Add test for bad cast with deferred projection equality
This commit is contained in:
parent
8973049549
commit
eb1f9babec
@ -0,0 +1,6 @@
|
||||
// compile-flags: -Ztrait-solver=next
|
||||
// known-bug: unknown
|
||||
|
||||
fn main() {
|
||||
(0u8 + 0u8) as char;
|
||||
}
|
@ -0,0 +1,9 @@
|
||||
error[E0271]: type mismatch resolving `char == <u8 as Add>::Output`
|
||||
--> $DIR/cast-checks-handling-projections.rs:5:5
|
||||
|
|
||||
LL | (0u8 + 0u8) as char;
|
||||
| ^^^^^^^^^^^ types differ
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
For more information about this error, try `rustc --explain E0271`.
|
Loading…
x
Reference in New Issue
Block a user