Lines Matching defs:RHS

72   bool operator==(const SparseBitVectorElement &RHS) const {
73 if (ElementIndex != RHS.ElementIndex)
76 if (Bits[i] != RHS.Bits[i])
81 bool operator!=(const SparseBitVectorElement &RHS) const {
82 return !(*this == RHS);
163 // Union this element with RHS and return true if this one changed.
164 bool unionWith(const SparseBitVectorElement &RHS) {
169 Bits[i] |= RHS.Bits[i];
176 // Return true if we have any bits in common with RHS
177 bool intersects(const SparseBitVectorElement &RHS) const {
179 if (RHS.Bits[i] & Bits[i])
185 // Intersect this Element with RHS and return true if this one changed.
187 bool intersectWith(const SparseBitVectorElement &RHS,
196 Bits[i] &= RHS.Bits[i];
207 // Intersect this Element with the complement of RHS and return true if this
210 bool intersectWithComplement(const SparseBitVectorElement &RHS,
219 Bits[i] &= ~RHS.Bits[i];
404 bool operator==(const SparseBitVectorIterator &RHS) const {
406 if (AtEnd && RHS.AtEnd)
410 return AtEnd == RHS.AtEnd && RHS.BitNumber == BitNumber;
413 bool operator!=(const SparseBitVectorIterator &RHS) const {
414 return !(*this == RHS);
420 SparseBitVectorIterator(const SparseBitVector<ElementSize> *RHS,
421 bool end = false):BitVector(RHS) {
441 SparseBitVector(const SparseBitVector &RHS) {
442 ElementListConstIter ElementIter = RHS.Elements.begin();
443 while (ElementIter != RHS.Elements.end()) {
457 SparseBitVector& operator=(const SparseBitVector& RHS) {
458 if (this == &RHS)
463 ElementListConstIter ElementIter = RHS.Elements.begin();
464 while (ElementIter != RHS.Elements.end()) {
549 bool operator!=(const SparseBitVector &RHS) const {
550 return !(*this == RHS);
553 bool operator==(const SparseBitVector &RHS) const {
555 ElementListConstIter Iter2 = RHS.Elements.begin();
557 for (; Iter1 != Elements.end() && Iter2 != RHS.Elements.end();
562 return Iter1 == Elements.end() && Iter2 == RHS.Elements.end();
565 // Union our bitmap with the RHS and return true if we changed.
566 bool operator|=(const SparseBitVector &RHS) {
567 if (this == &RHS)
572 ElementListConstIter Iter2 = RHS.Elements.begin();
574 // If RHS is empty, we are done
575 if (RHS.Elements.empty())
578 while (Iter2 != RHS.Elements.end()) {
596 // Intersect our bitmap with the RHS and return true if ours changed.
597 bool operator&=(const SparseBitVector &RHS) {
598 if (this == &RHS)
603 ElementListConstIter Iter2 = RHS.Elements.begin();
606 if (Elements.empty() && RHS.Elements.empty())
610 while (Iter2 != RHS.Elements.end()) {
644 // Intersect our bitmap with the complement of the RHS and return true
646 bool intersectWithComplement(const SparseBitVector &RHS) {
647 if (this == &RHS) {
657 ElementListConstIter Iter2 = RHS.Elements.begin();
659 // If either our bitmap or RHS is empty, we are done
660 if (Elements.empty() || RHS.Elements.empty())
664 while (Iter2 != RHS.Elements.end()) {
691 bool intersectWithComplement(const SparseBitVector<ElementSize> *RHS) const {
692 return intersectWithComplement(*RHS);
760 bool intersects(const SparseBitVector<ElementSize> *RHS) const {
761 return intersects(*RHS);
764 // Return true if we share any bits in common with RHS
765 bool intersects(const SparseBitVector<ElementSize> &RHS) const {
767 ElementListConstIter Iter2 = RHS.Elements.begin();
770 if (Elements.empty() && RHS.Elements.empty())
774 while (Iter2 != RHS.Elements.end()) {
793 // also set in RHS.
794 bool contains(const SparseBitVector<ElementSize> &RHS) const {
796 Result &= RHS;
797 return (Result == RHS);
836 const SparseBitVector<ElementSize> *RHS) {
837 return LHS |= *RHS;
842 const SparseBitVector<ElementSize> &RHS) {
843 return LHS->operator|=(RHS);
848 const SparseBitVector<ElementSize> &RHS) {
849 return LHS->operator&=(RHS);
854 const SparseBitVector<ElementSize> *RHS) {
855 return LHS &= *RHS;
863 const SparseBitVector<ElementSize> &RHS) {
865 Result |= RHS;
872 const SparseBitVector<ElementSize> &RHS) {
874 Result &= RHS;
881 const SparseBitVector<ElementSize> &RHS) {
883 Result.intersectWithComplement(LHS, RHS);