diff options
| author | bors <bors@rust-lang.org> | 2025-05-09 05:16:40 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2025-05-09 05:16:40 +0000 |
| commit | a7b1b24587dcbebf12455c41ed828d9b486487be (patch) | |
| tree | 27891e5f5afa94ed826ea1805f509822e00c8d73 /compiler/rustc_parse/src/parser | |
| parent | c8b7f32434c0306db5c1b974ee43443746098a92 (diff) | |
| parent | 0984db553ddd25c0d16ef68b91bd731825309ac5 (diff) | |
| download | rust-a7b1b24587dcbebf12455c41ed828d9b486487be.tar.gz rust-a7b1b24587dcbebf12455c41ed828d9b486487be.zip | |
Auto merge of #140252 - nnethercote:rm-Ident-empty, r=oli-obk
Remove `Ident::empty` All uses have been removed. And it's nonsensical: an identifier by definition has at least one char. r? `@oli-obk`
Diffstat (limited to 'compiler/rustc_parse/src/parser')
| -rw-r--r-- | compiler/rustc_parse/src/parser/expr.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_parse/src/parser/expr.rs b/compiler/rustc_parse/src/parser/expr.rs index f3b53971b29..2a7910a6af4 100644 --- a/compiler/rustc_parse/src/parser/expr.rs +++ b/compiler/rustc_parse/src/parser/expr.rs @@ -3828,7 +3828,7 @@ impl<'a> Parser<'a> { // Convert `label` -> `'label`, // so that nameres doesn't complain about non-existing label let label = format!("'{}", ident.name); - let ident = Ident { name: Symbol::intern(&label), span: ident.span }; + let ident = Ident::new(Symbol::intern(&label), ident.span); self.dcx().emit_err(errors::ExpectedLabelFoundIdent { span: ident.span, |
