Use def_key in tcx.item_name
when possible.
This commit is contained in:
parent
b5dfa6a78d
commit
f89d64d7aa
10 changed files with 41 additions and 42 deletions
|
@ -147,6 +147,11 @@ impl DefKey {
|
|||
// DefPathHashes in this DefPathTable.
|
||||
DefPathHash::new(parent.stable_crate_id(), local_hash)
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn get_opt_name(&self) -> Option<Symbol> {
|
||||
self.disambiguated_data.data.get_opt_name()
|
||||
}
|
||||
}
|
||||
|
||||
/// A pair of `DefPathData` and an integer disambiguator. The integer is
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue