Skip to main content

Module hashset

Module hashset 

Source
Expand description

An unordered set.

An immutable hash set using hash array mapped tries.

Most operations on this set are O(logx n) for a suitably high x that it should be nearly O(1) for most sets. Because of this, it’s a great choice for a generic set as long as you don’t mind that values will need to implement Hash and Eq.

Values will have a predictable order based on the hasher being used. Unless otherwise specified, this will be the standard RandomState hasher.

Macros§

hashset
Construct a set from a sequence of values.

Structs§

ConsumingIter
A consuming iterator over the elements of a set.
GenericHashSet
An unordered set.
Iter
An iterator over the elements of a set.

Type Aliases§

HashSet
Type alias for GenericHashSet that uses std::hash::RandomState as the default hasher and DefaultSharedPtr as the pointer type.