Struct Set

simplified Set() code with some convenience methods, could use a drop-in implementation later.

struct Set(T) ;

Fields

NameTypeDescription
_set bool[T]

Methods

NameDescription
fill (rhs) Fill an existing set with elements from an array
from (range) Build a new Set out of the provided range
fromBinary (dg, opts) Returns a newly instantiated Set of type SetT
fromString (str) Support for Vibe.d deserialization
opApply (dg) Walk over all elements and call dg(elem)
opApplyImpl (dg) Walk over all elements and call dg(elem)
opSlice () Provide a range to iterate on
put (key) Put an element in the set
remove (key) Remove an element from the set if present, does nothing otherwise
serialize (dg) Serialization support
toString () Support for -checkaction=context in LDC 1.26.0, can be removed when LDC 1.27.0 is the oldest supported release

Aliases

NameDescription
SinkT Helper type for toString