/** * Mutates the `HashSet` within the context of the provided function. * * @tsplus static HashSet.Aspects mutate * @tsplus pipeable HashSet mutate */ export function mutate(f: (set: HashSet) => void) { return (self: HashSet): HashSet => { const transient = self.beginMutation f(transient) return transient.endMutation } }