diff options
| author | Nilstrieb <48135649+Nilstrieb@users.noreply.github.com> | 2022-12-28 18:06:11 +0100 |
|---|---|---|
| committer | Nilstrieb <48135649+Nilstrieb@users.noreply.github.com> | 2022-12-28 18:52:36 +0100 |
| commit | 9067e4417e52643596ae8dbc4ec6369a0d856b45 (patch) | |
| tree | c2a5b6d238110bb40a1a06db2f288e01f4e1b9c0 /compiler/rustc_parse/src/parser | |
| parent | a1fc71196a5554eafc5dd9a1b4e0c159717141e0 (diff) | |
| download | rust-9067e4417e52643596ae8dbc4ec6369a0d856b45.tar.gz rust-9067e4417e52643596ae8dbc4ec6369a0d856b45.zip | |
Rename `Rptr` to `Ref` in AST and HIR
The name makes a lot more sense, and `ty::TyKind` calls it `Ref` already as well.
Diffstat (limited to 'compiler/rustc_parse/src/parser')
| -rw-r--r-- | compiler/rustc_parse/src/parser/diagnostics.rs | 2 | ||||
| -rw-r--r-- | compiler/rustc_parse/src/parser/ty.rs | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/compiler/rustc_parse/src/parser/diagnostics.rs b/compiler/rustc_parse/src/parser/diagnostics.rs index 61fe379c3e9..67e701b00ea 100644 --- a/compiler/rustc_parse/src/parser/diagnostics.rs +++ b/compiler/rustc_parse/src/parser/diagnostics.rs @@ -1229,7 +1229,7 @@ impl<'a> Parser<'a> { let sum_span = ty.span.to(self.prev_token.span); let sub = match &ty.kind { - TyKind::Rptr(lifetime, mut_ty) => { + TyKind::Ref(lifetime, mut_ty) => { let sum_with_parens = pprust::to_string(|s| { s.s.word("&"); s.print_opt_lifetime(lifetime); diff --git a/compiler/rustc_parse/src/parser/ty.rs b/compiler/rustc_parse/src/parser/ty.rs index fc26278909c..a87f6d194ba 100644 --- a/compiler/rustc_parse/src/parser/ty.rs +++ b/compiler/rustc_parse/src/parser/ty.rs @@ -501,7 +501,7 @@ impl<'a> Parser<'a> { self.bump_with((dyn_tok, dyn_tok_sp)); } let ty = self.parse_ty_no_plus()?; - Ok(TyKind::Rptr(opt_lifetime, MutTy { ty, mutbl })) + Ok(TyKind::Ref(opt_lifetime, MutTy { ty, mutbl })) } // Parses the `typeof(EXPR)`. |
