about summary refs log tree commit diff
path: root/compiler/rustc_hir/src/hir.rs
diff options
context:
space:
mode:
authorMatthias Krüger <476013+matthiaskrgr@users.noreply.github.com>2025-05-23 13:34:20 +0200
committerGitHub <noreply@github.com>2025-05-23 13:34:20 +0200
commit225ed8b9cfe6fb794c41fc9b26db3cf719fe437d (patch)
treec468d436f7bbfbcc309848005c7dae43419895e3 /compiler/rustc_hir/src/hir.rs
parent893494c90fe449ff223dae62149cd5fb1c03f957 (diff)
parent849cabf4c4a97f0a1c6320993b08bf8e6068e58f (diff)
downloadrust-225ed8b9cfe6fb794c41fc9b26db3cf719fe437d.tar.gz
rust-225ed8b9cfe6fb794c41fc9b26db3cf719fe437d.zip
Rollup merge of #141376 - nnethercote:rename-kw-Empty, r=petrochenkov
Rename `kw::Empty` as `sym::empty`.

Because the empty string is not a keyword.

r? `@petrochenkov`
Diffstat (limited to 'compiler/rustc_hir/src/hir.rs')
-rw-r--r--compiler/rustc_hir/src/hir.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_hir/src/hir.rs b/compiler/rustc_hir/src/hir.rs
index fa1d1ec0a86..f63ab303689 100644
--- a/compiler/rustc_hir/src/hir.rs
+++ b/compiler/rustc_hir/src/hir.rs
@@ -85,7 +85,7 @@ impl From<Ident> for LifetimeSyntax {
     fn from(ident: Ident) -> Self {
         let name = ident.name;
 
-        if name == kw::Empty {
+        if name == sym::empty {
             unreachable!("A lifetime name should never be empty");
         } else if name == kw::UnderscoreLifetime {
             LifetimeSyntax::Anonymous