cmpStablePtr# / hashing?
Currently, there are primops reallyUnsafePtrEquality#
and eqStablePtr#
, which allow us to compare two pointers for equality. I'm wondering whether we could also have comparison operations, or hashing operations, which would allow a user to collect MutVar
s or StablePtr
s into a (Hash)Map
.
I assume that we can't have reallyUnsafePtrComparison#
because the GC provides no ordering guarantees. But what about StablePtr
s? Could we have a comparison operation, or a hashing function?