about summary refs log tree commit diff
path: root/compiler/rustc_parse/src/parser
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2021-03-23 02:01:14 +0000
committerbors <bors@rust-lang.org>2021-03-23 02:01:14 +0000
commit2bd94f4aa9683158c7df96b9661be193c39a55ed (patch)
treeef88985b7237c4b6f77c27e17e9fbce5577d29f1 /compiler/rustc_parse/src/parser
parent5d04957a4b4714f71d38326fc96a0b0ef6dc5800 (diff)
parent263c85875cb3aceced6cc712961234fc61d71cba (diff)
downloadrust-2bd94f4aa9683158c7df96b9661be193c39a55ed.tar.gz
rust-2bd94f4aa9683158c7df96b9661be193c39a55ed.zip
Auto merge of #83398 - JohnTitor:rollup-om80krv, r=JohnTitor
Rollup of 7 pull requests

Successful merges:

 - #80705 (Update Source Code Pro and include italics)
 - #81917 (Update RELEASES.md for 1.51.0)
 - #82732 (Remove theme.js file)
 - #83356 (rustdoc: Replace pair of `Option`s with an enum)
 - #83384 (rename :pat2018 -> :pat2015)
 - #83385 (:arrow_up: rust-analyzer)
 - #83389 (add rust-analyzer rustc_private option in librustdoc Cargo.toml)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
Diffstat (limited to 'compiler/rustc_parse/src/parser')
-rw-r--r--compiler/rustc_parse/src/parser/nonterminal.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/compiler/rustc_parse/src/parser/nonterminal.rs b/compiler/rustc_parse/src/parser/nonterminal.rs
index 464524e3c06..fc25e883666 100644
--- a/compiler/rustc_parse/src/parser/nonterminal.rs
+++ b/compiler/rustc_parse/src/parser/nonterminal.rs
@@ -61,7 +61,7 @@ impl<'a> Parser<'a> {
                 },
                 _ => false,
             },
-            NonterminalKind::Pat2018 { .. } | NonterminalKind::Pat2021 { .. } => match token.kind {
+            NonterminalKind::Pat2015 { .. } | NonterminalKind::Pat2021 { .. } => match token.kind {
                 token::Ident(..) |                  // box, ref, mut, and other identifiers (can stricten)
                 token::OpenDelim(token::Paren) |    // tuple pattern
                 token::OpenDelim(token::Bracket) |  // slice pattern
@@ -118,9 +118,9 @@ impl<'a> Parser<'a> {
                     return Err(self.struct_span_err(self.token.span, "expected a statement"));
                 }
             },
-            NonterminalKind::Pat2018 { .. } | NonterminalKind::Pat2021 { .. } => {
+            NonterminalKind::Pat2015 { .. } | NonterminalKind::Pat2021 { .. } => {
                 token::NtPat(self.collect_tokens_no_attrs(|this| match kind {
-                    NonterminalKind::Pat2018 { .. } => this.parse_pat_no_top_alt(None),
+                    NonterminalKind::Pat2015 { .. } => this.parse_pat_no_top_alt(None),
                     NonterminalKind::Pat2021 { .. } => {
                         this.parse_pat_allow_top_alt(None, RecoverComma::No)
                     }