From 4b266f1c0df9732bbdea44b0df3d459d4cf2756d Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Thu, 19 Sep 2013 12:09:52 -0700 Subject: Stop accepting 'impl ...;', require {} instead Progress on #7981 --- src/libsyntax/parse/parser.rs | 4 +++- 1 file changed, 3 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 4aad5c24d0f..5a0ccac2cdb 100644 --- a/src/libsyntax/parse/parser.rs +++ b/src/libsyntax/parse/parser.rs @@ -3852,7 +3852,9 @@ impl Parser { } let mut meths = ~[]; - if !self.eat(&token::SEMI) { + if self.eat(&token::SEMI) { + self.obsolete(*self.span, ObsoleteEmptyImpl); + } else { self.expect(&token::LBRACE); while !self.eat(&token::RBRACE) { meths.push(self.parse_method()); -- cgit 1.4.1-3-g733a5