From 815765dadeb011180ad3ea0ce02c9cc59f8c93cc Mon Sep 17 00:00:00 2001 From: Lamb Date: Wed, 30 May 2018 13:06:05 +0200 Subject: Issue #50974: Fix compilation error and test --- src/libsyntax/parse/parser.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/libsyntax/parse') diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs index d6916c1c344..456054ee251 100644 --- a/src/libsyntax/parse/parser.rs +++ b/src/libsyntax/parse/parser.rs @@ -776,7 +776,7 @@ impl<'a> Parser<'a> { err.span_label(self.span, format!("expected identifier, found {}", token_descr)); } else { err.span_label(self.span, "expected identifier"); - if self.token == token::Comma && self.look_ahead(1, |t| *t.is_ident()) { + if self.token == token::Comma && self.look_ahead(1, |t| t.is_ident()) { err.span_suggestion(self.span, "remove this comma", "".into()); } } -- cgit 1.4.1-3-g733a5