mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-01 11:31:15 +00:00
Merge #8944
8944: minor: explain why nested `TypeRef` aren't interned r=jonas-schievink a=jonas-schievink bors r+ Co-authored-by: Jonas Schievink <jonasschievink@gmail.com>
This commit is contained in:
commit
96e5412f88
@ -72,6 +72,10 @@ impl TraitRef {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// Compare ty::Ty
|
/// Compare ty::Ty
|
||||||
|
///
|
||||||
|
/// Note: Most users of `TypeRef` that end up in the salsa database intern it using
|
||||||
|
/// `Interned<TypeRef>` to save space. But notably, nested `TypeRef`s are not interned, since that
|
||||||
|
/// does not seem to save any noticeable amount of memory.
|
||||||
#[derive(Clone, PartialEq, Eq, Hash, Debug)]
|
#[derive(Clone, PartialEq, Eq, Hash, Debug)]
|
||||||
pub enum TypeRef {
|
pub enum TypeRef {
|
||||||
Never,
|
Never,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user