MCPcopy Index your code
hub / github.com/ciphermodelabs/ciphercore / DynEqHash

Interface DynEqHash

ciphercore-base/src/custom_ops.rs:29–33  ·  view source on GitHub ↗

This trait can be used to compare and hash trait objects. Based on and .

Source from the content-addressed store, hash-verified

27/// and
28/// <https://stackoverflow.com/questions/64838355/how-do-i-create-a-hashmap-with-type-erased-keys>.
29pub trait DynEqHash {
30 fn as_any(&self) -> &dyn Any;
31 fn equals(&self, _: &dyn Any) -> bool;
32 fn hash(&self) -> u64;
33}
34
35impl<T: 'static + Eq + Hash> DynEqHash for T {
36 fn as_any(&self) -> &dyn Any {

Callers

nothing calls this directly

Implementers 1

custom_ops.rsciphercore-base/src/custom_ops.rs

Calls

no outgoing calls

Tested by

no test coverage detected