about summary refs log tree commit diff
path: root/src/comp
diff options
context:
space:
mode:
authorGraydon Hoare <graydon@mozilla.com>2011-03-29 15:40:21 -0700
committerGraydon Hoare <graydon@mozilla.com>2011-03-29 15:40:21 -0700
commitf6490a6f03dd997d7cb801dff9d48a56b336fccc (patch)
treeb4bce6ff2a05bfd58e6814d37c0cc834d0682150 /src/comp
parentd7a6c83c8c952e1f22e9b62f1b25705167ac0bb9 (diff)
downloadrust-f6490a6f03dd997d7cb801dff9d48a56b336fccc.tar.gz
rust-f6490a6f03dd997d7cb801dff9d48a56b336fccc.zip
Ignore 'mutable foo' in plain field contexts.
Diffstat (limited to 'src/comp')
-rw-r--r--src/comp/front/parser.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/comp/front/parser.rs b/src/comp/front/parser.rs
index 06e22ea8818..7bec44e64b5 100644
--- a/src/comp/front/parser.rs
+++ b/src/comp/front/parser.rs
@@ -1003,6 +1003,12 @@ impure fn parse_dot_or_call_expr(parser p) -> @ast.expr {
 
 impure fn parse_prefix_expr(parser p) -> @ast.expr {
 
+    if (p.peek() == token.MUTABLE) {
+        p.bump();
+        p.get_session().span_warn(p.get_span(),
+            "ignoring deprecated 'mutable' prefix operator");
+    }
+
     auto lo = p.get_span();
     auto hi = lo;