diff options
| author | Josh Triplett <josh@joshtriplett.org> | 2024-12-17 14:33:10 -0800 |
|---|---|---|
| committer | Josh Triplett <josh@joshtriplett.org> | 2024-12-17 14:33:10 -0800 |
| commit | a105cd606628b07e79ab343cc183a176e278c809 (patch) | |
| tree | 051f572eb6a1fcf3cb4541d4c427e0c13d02a8bd /compiler/rustc_parse/src | |
| parent | a4cb3c831823d9baa56c3d90514b75b2660116fa (diff) | |
| download | rust-a105cd606628b07e79ab343cc183a176e278c809.tar.gz rust-a105cd606628b07e79ab343cc183a176e278c809.zip | |
Use field init shorthand where possible
Field init shorthand allows writing initializers like `tcx: tcx` as `tcx`. The compiler already uses it extensively. Fix the last few places where it isn't yet used.
Diffstat (limited to 'compiler/rustc_parse/src')
| -rw-r--r-- | compiler/rustc_parse/src/parser/pat.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_parse/src/parser/pat.rs b/compiler/rustc_parse/src/parser/pat.rs index 255be721525..8706ae4a426 100644 --- a/compiler/rustc_parse/src/parser/pat.rs +++ b/compiler/rustc_parse/src/parser/pat.rs @@ -1648,7 +1648,7 @@ impl<'a> Parser<'a> { ident: prev_field, }) } else { - self.dcx().create_err(AtInStructPattern { span: span }) + self.dcx().create_err(AtInStructPattern { span }) } } |
