Rename kw::Empty as sym::empty.

Because the empty string is not a keyword.
This commit is contained in:
Nicholas Nethercote
2025-05-22 11:55:22 +10:00
parent bf64d66bd5
commit 849cabf4c4
9 changed files with 31 additions and 32 deletions

View File

@@ -20,7 +20,7 @@ use rustc_middle::ty::{
self, FloatTy, GenericArg, GenericArgKind, Instance, IntTy, ReifyReason, Ty, TyCtxt,
TypeVisitable, TypeVisitableExt, UintTy,
};
use rustc_span::kw;
use rustc_span::sym;
pub(super) fn mangle<'tcx>(
tcx: TyCtxt<'tcx>,
@@ -902,7 +902,7 @@ impl<'tcx> Printer<'tcx> for SymbolMangler<'tcx> {
print_prefix,
ns,
disambiguated_data.disambiguator as u64,
name.unwrap_or(kw::Empty).as_str(),
name.unwrap_or(sym::empty).as_str(),
)
}