blob: 68e4762b8d91de6cc424182f83dd30c28be9a679 [file] [log] [blame] [edit]
error: cast cannot be followed by a postfix match
--> $DIR/match-after-as.rs:4:5
|
LL | 1 as i32.match {};
| ^^^^^^^^
|
help: try surrounding the expression in parentheses
|
LL | (1 as i32).match {};
| + +
error[E0004]: non-exhaustive patterns: type `i32` is non-empty
--> $DIR/match-after-as.rs:4:5
|
LL | 1 as i32.match {};
| ^^^^^^^^
|
= note: the matched value is of type `i32`
help: ensure that all possible cases are being handled by adding a match arm with a wildcard pattern as shown
|
LL ~ 1 as i32.match {
LL + _ => todo!(),
LL ~ };
|
error: aborting due to 2 previous errors
For more information about this error, try `rustc --explain E0004`.