about summary refs log tree commit diff
path: root/src/libsyntax/parse
diff options
context:
space:
mode:
Diffstat (limited to 'src/libsyntax/parse')
-rw-r--r--src/libsyntax/parse/parser/pat.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libsyntax/parse/parser/pat.rs b/src/libsyntax/parse/parser/pat.rs
index 55c534e56ce..e288346a329 100644
--- a/src/libsyntax/parse/parser/pat.rs
+++ b/src/libsyntax/parse/parser/pat.rs
@@ -417,14 +417,14 @@ impl<'a> Parser<'a> {
             *sub = Some(lhs);
 
             self.struct_span_err(sp, "pattern on wrong side of `@`")
-                .span_label(lhs_span, "pattern on the left, should be to the right")
-                .span_label(rhs.span, "binding on the right, should be to the left")
+                .span_label(lhs_span, "pattern on the left, should be on the right")
+                .span_label(rhs.span, "binding on the right, should be on the left")
                 .span_suggestion(sp, "switch the order", pprust::pat_to_string(&rhs), applicability)
                 .emit();
         } else {
             // The special case above doesn't apply so we may have e.g. `A(x) @ B(y)`.
             rhs.kind = PatKind::Wild;
-            self.struct_span_err(sp, "left-hand side of `@` must be a binding pattern")
+            self.struct_span_err(sp, "left-hand side of `@` must be a binding")
                 .span_label(lhs.span, "interpreted as a pattern, not a binding")
                 .span_label(rhs.span, "also a pattern")
                 .note("bindings are `x`, `mut x`, `ref x`, and `ref mut x`")