BitsetsNET.BitsetContainer.IOr C# (CSharp) Method

IOr() public method

Computes the in-place bitwise OR of this container with another (union). The current container is generally modified, whereas the provided container(x) is unaffected.May generate a new container.
public IOr ( ArrayContainer x ) : Container
x ArrayContainer Other container
return Container
        public override Container IOr(ArrayContainer x)
        {
            int c = x.Cardinality;
            for (int k = 0; k < c; ++k)
            {
                ushort v = x.Content[k];
                int i = v >> 6;

                long w = this.Bitmap[i];
                long aft = w | (1L << v);
                this.Bitmap[i] = aft;

                this.Cardinality += (int)((w - aft) >> 63);
            }
            return this;
        }

Same methods

BitsetContainer::IOr ( BitsetContainer x ) : Container