From aadcf29766553a6b6ed8a3c2f50193ebd674b7a7 Mon Sep 17 00:00:00 2001 From: Huon Wilson Date: Sat, 1 Feb 2014 23:18:45 +1100 Subject: syntax: add an obsolete syntax warning for @[]. --- src/libsyntax/parse/parser.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/libsyntax/parse/parser.rs') diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs index fb679fa0460..ec2a13c5a0f 100644 --- a/src/libsyntax/parse/parser.rs +++ b/src/libsyntax/parse/parser.rs @@ -2294,7 +2294,10 @@ impl Parser { // HACK: turn @[...] into a @-vec ex = match e.node { ExprVec(..) | - ExprRepeat(..) => ExprVstore(e, ExprVstoreBox), + ExprRepeat(..) => { + self.obsolete(e.span, ObsoleteManagedVec); + ExprVstore(e, ExprVstoreBox) + } ExprLit(lit) if lit_is_str(lit) => { self.obsolete(self.last_span, ObsoleteManagedString); ExprVstore(e, ExprVstoreBox) -- cgit 1.4.1-3-g733a5