diff options
| author | Yuki Okushi <huyuumi.dev@gmail.com> | 2021-03-23 10:15:43 +0900 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-03-23 10:15:43 +0900 |
| commit | 50d048f1426a9b88031bb0c25e9c1ea4edacbfc7 (patch) | |
| tree | c1478f749b2ff1c385960b04e176694b641b1b24 /compiler/rustc_parse/src | |
| parent | 20006b1891dbacb974dbe73af6c98c751b4dfcdb (diff) | |
| parent | 8c4b3dbb50621b661aa63ad1791eed2d52564dcb (diff) | |
| download | rust-50d048f1426a9b88031bb0c25e9c1ea4edacbfc7.tar.gz rust-50d048f1426a9b88031bb0c25e9c1ea4edacbfc7.zip | |
Rollup merge of #83384 - mark-i-m:rename-pat2018, r=joshtriplett
rename :pat2018 -> :pat2015 as requested by T-lang on zulip: https://rust-lang.zulipchat.com/#narrow/stream/213817-t-lang/topic/or.20patterns/near/231133873 No functional changes here... just renaming. r? `@nikomatsakis`
Diffstat (limited to 'compiler/rustc_parse/src')
| -rw-r--r-- | compiler/rustc_parse/src/parser/nonterminal.rs | 6 |
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) } |
