Use kw::Empty for elided lifetimes in path.

This commit is contained in:
Camille GILLOT
2022-11-06 11:40:31 +00:00
parent 41090346d8
commit 1c737d6997
12 changed files with 281 additions and 83 deletions

View File

@@ -530,7 +530,7 @@ impl ty::EarlyBoundRegion {
/// Does this early bound region have a name? Early bound regions normally
/// always have names except when using anonymous lifetimes (`'_`).
pub fn has_name(&self) -> bool {
self.name != kw::UnderscoreLifetime
self.name != kw::UnderscoreLifetime && self.name != kw::Empty
}
}