mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-01 15:01:51 +00:00
pprust: p1@p2
-> p1 @ p2
This commit is contained in:
parent
3a9f8deb1d
commit
16266a5405
@ -2381,7 +2381,8 @@ impl<'a> State<'a> {
|
||||
}
|
||||
self.print_ident(ident);
|
||||
if let Some(ref p) = *sub {
|
||||
self.s.word("@");
|
||||
self.s.space();
|
||||
self.s.word_space("@");
|
||||
self.print_pat(p);
|
||||
}
|
||||
}
|
||||
|
@ -15,7 +15,7 @@ fn main() {
|
||||
//~| pattern on the left, should be on the right
|
||||
//~| binding on the right, should be on the left
|
||||
//~| HELP switch the order
|
||||
//~| SUGGESTION y@Some(x)
|
||||
//~| SUGGESTION y @ Some(x)
|
||||
_ => {}
|
||||
}
|
||||
|
||||
@ -34,7 +34,7 @@ fn main() {
|
||||
//~| pattern on the left, should be on the right
|
||||
//~| binding on the right, should be on the left
|
||||
//~| HELP switch the order
|
||||
//~| SUGGESTION e@1 ..=5
|
||||
//~| SUGGESTION e @ 1 ..=5
|
||||
_ => {}
|
||||
}
|
||||
}
|
||||
|
@ -6,7 +6,7 @@ LL | Some(x) @ y => {}
|
||||
| | |
|
||||
| | binding on the right, should be on the left
|
||||
| pattern on the left, should be on the right
|
||||
| help: switch the order: `y@Some(x)`
|
||||
| help: switch the order: `y @ Some(x)`
|
||||
|
||||
error: left-hand side of `@` must be a binding
|
||||
--> $DIR/intersection-patterns.rs:23:9
|
||||
@ -27,7 +27,7 @@ LL | 1 ..= 5 @ e => {}
|
||||
| | |
|
||||
| | binding on the right, should be on the left
|
||||
| pattern on the left, should be on the right
|
||||
| help: switch the order: `e@1 ..=5`
|
||||
| help: switch the order: `e @ 1 ..=5`
|
||||
|
||||
error: aborting due to 3 previous errors
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user