diff options
| author | Alexander Regueiro <alexreg@me.com> | 2019-09-06 03:56:45 +0100 |
|---|---|---|
| committer | Alexander Regueiro <alexreg@me.com> | 2019-09-07 16:29:04 +0100 |
| commit | 49d2fd1725510fd3bf6f2937e178b1aa055ddb02 (patch) | |
| tree | a04455dea49b29d2c981573bd920116f0418024b /src/libsyntax/parse/parser/pat.rs | |
| parent | ef54f57c5b9d894a38179d09b00610c1b337b086 (diff) | |
| download | rust-49d2fd1725510fd3bf6f2937e178b1aa055ddb02.tar.gz rust-49d2fd1725510fd3bf6f2937e178b1aa055ddb02.zip | |
Aggregation of cosmetic changes made during work on REPL PRs: libsyntax
Diffstat (limited to 'src/libsyntax/parse/parser/pat.rs')
| -rw-r--r-- | src/libsyntax/parse/parser/pat.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libsyntax/parse/parser/pat.rs b/src/libsyntax/parse/parser/pat.rs index 669f657160b..49f8d58c6a7 100644 --- a/src/libsyntax/parse/parser/pat.rs +++ b/src/libsyntax/parse/parser/pat.rs @@ -844,14 +844,14 @@ impl<'a> Parser<'a> { // Check if a colon exists one ahead. This means we're parsing a fieldname. let hi; let (subpat, fieldname, is_shorthand) = if self.look_ahead(1, |t| t == &token::Colon) { - // Parsing a pattern of the form "fieldname: pat" + // Parsing a pattern of the form `fieldname: pat`. let fieldname = self.parse_field_name()?; self.bump(); let pat = self.parse_pat_with_or_inner()?; hi = pat.span; (pat, fieldname, false) } else { - // Parsing a pattern of the form "(box) (ref) (mut) fieldname" + // Parsing a pattern of the form `(box) (ref) (mut) fieldname`. let is_box = self.eat_keyword(kw::Box); let boxed_span = self.token.span; let is_ref = self.eat_keyword(kw::Ref); |
