diff options
| author | Christian Poveda <git@pvdrz.com> | 2022-05-16 22:23:32 -0500 |
|---|---|---|
| committer | Christian Poveda <git@pvdrz.com> | 2022-05-16 22:23:32 -0500 |
| commit | 7cafefec4a3dc847d029f62893eb7b023ac6887d (patch) | |
| tree | 24d9c7dcb2d34c676f01ee77a9935700058612b9 /compiler/rustc_parse/src/parser | |
| parent | 7e8517df61b45195a9547c05b3fd31ade91f9ae1 (diff) | |
| download | rust-7cafefec4a3dc847d029f62893eb7b023ac6887d.tar.gz rust-7cafefec4a3dc847d029f62893eb7b023ac6887d.zip | |
keep bounds where they were
Diffstat (limited to 'compiler/rustc_parse/src/parser')
| -rw-r--r-- | compiler/rustc_parse/src/parser/diagnostics.rs | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/compiler/rustc_parse/src/parser/diagnostics.rs b/compiler/rustc_parse/src/parser/diagnostics.rs index a7462dcb52f..3b2ce0de509 100644 --- a/compiler/rustc_parse/src/parser/diagnostics.rs +++ b/compiler/rustc_parse/src/parser/diagnostics.rs @@ -1286,14 +1286,13 @@ impl<'a> Parser<'a> { } self.bump(); // `+` + let bounds = self.parse_generic_bounds(None)?; let sum_span = ty.span.to(self.prev_token.span); let sum_with_parens: String; let sub = match ty.kind { TyKind::Rptr(ref lifetime, ref mut_ty) => { - let bounds = self.parse_generic_bounds(None)?; - sum_with_parens = pprust::to_string(|s| { s.s.word("&"); s.print_opt_lifetime(lifetime); |
