Make PackedFingerprint's Fingerprint private

This commit is contained in:
Tyson Nottingham
2020-11-18 15:10:43 -08:00
parent f09d474836
commit 05dde137ca
4 changed files with 25 additions and 8 deletions

View File

@@ -62,7 +62,7 @@ impl<K: DepKind> DepNode<K> {
/// does not require any parameters.
pub fn new_no_params(kind: K) -> DepNode<K> {
debug_assert!(!kind.has_params());
DepNode { kind, hash: PackedFingerprint(Fingerprint::ZERO) }
DepNode { kind, hash: Fingerprint::ZERO.into() }
}
pub fn construct<Ctxt, Key>(tcx: Ctxt, kind: K, arg: &Key) -> DepNode<K>
@@ -71,7 +71,7 @@ impl<K: DepKind> DepNode<K> {
Key: DepNodeParams<Ctxt>,
{
let hash = arg.to_fingerprint(tcx);
let dep_node = DepNode { kind, hash: PackedFingerprint(hash) };
let dep_node = DepNode { kind, hash: hash.into() };
#[cfg(debug_assertions)]
{