MCPcopy Create free account
hub / github.com/Gecode/gecode / replace_and_decrease

Method replace_and_decrease

gecode/int/extensional/bit-set.hpp:132–145  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

130
131 template<class IndexType>
132 forceinline void
133 BitSet<IndexType>::replace_and_decrease(IndexType i, BitSetData w) {
134 assert(_limit > 0U);
135 BitSetData w_i = _bits[i];
136 if (w != w_i) {
137 _bits[i] = w;
138 if (w.none()) {
139 assert(_bits[i].none());
140 _limit--;
141 _bits[i] = _bits[_limit];
142 _index[i] = _index[_limit];
143 }
144 }
145 }
146
147 template<class IndexType>
148 forceinline void

Callers

nothing calls this directly

Calls 1

noneMethod · 0.45

Tested by

no test coverage detected