pub fn toggleSet(self: *Self, toggles: Self) void
Flips all bits in this bit set which are present in the toggles bit set. Both sets must have the same bit_length.
self: *Self
toggles: Self
912 913 914 915 916 917 918
pub fn toggleSet(self: *Self, toggles: Self) void { assert(toggles.bit_length == self.bit_length); const num_masks = numMasks(self.bit_length); for (self.masks[0..num_masks], 0..) |*mask, i| { mask.* ^= toggles.masks[i]; } }
Flips all bits in this bit set which are present in the toggles bit set. Both sets must have the same bit_length.