diff options
| author | Mazdak Farrokhzad <twingoow@gmail.com> | 2019-12-03 15:32:05 +0100 |
|---|---|---|
| committer | Mazdak Farrokhzad <twingoow@gmail.com> | 2019-12-20 22:41:29 +0100 |
| commit | 948ff674f927c571bd43acf65bda9a488b7f640e (patch) | |
| tree | e416722766a5fe1a227b3127a5d2b9850ec961b1 /src/librustc_parse/parser | |
| parent | 4311a4d7f9ea6a6b0638d8fbc447825075d9be94 (diff) | |
| download | rust-948ff674f927c571bd43acf65bda9a488b7f640e.tar.gz rust-948ff674f927c571bd43acf65bda9a488b7f640e.zip | |
use mk_expr_err more
Diffstat (limited to 'src/librustc_parse/parser')
| -rw-r--r-- | src/librustc_parse/parser/expr.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/librustc_parse/parser/expr.rs b/src/librustc_parse/parser/expr.rs index 9a22641ce81..955cdb7b8e3 100644 --- a/src/librustc_parse/parser/expr.rs +++ b/src/librustc_parse/parser/expr.rs @@ -890,7 +890,7 @@ impl<'a> Parser<'a> { // 2 | foo(bar(; // | ^ expected expression self.bump(); - Ok(self.mk_expr(self.token.span, ExprKind::Err, ThinVec::new())) + Ok(self.mk_expr_err(self.token.span)) } else if self.token.span.rust_2018() { // `Span::rust_2018()` is somewhat expensive; don't get it repeatedly. if self.check_keyword(kw::Async) { |
