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

Method propagate

gecode/int/arithmetic/mult.hpp:146–169  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

144
145 template<class View, PropCond pc>
146 ExecStatus
147 MultZeroOne<View,pc>::propagate(Space& home, const ModEventDelta&) {
148 switch (equal(x0,0)) {
149 case RT_FALSE:
150 GECODE_ME_CHECK(x1.eq(home,1));
151 break;
152 case RT_TRUE:
153 break;
154 case RT_MAYBE:
155 switch (equal(x1,1)) {
156 case RT_FALSE:
157 GECODE_ME_CHECK(x0.eq(home,0));
158 break;
159 case RT_TRUE:
160 break;
161 case RT_MAYBE:
162 return ES_FIX;
163 default: GECODE_NEVER;
164 }
165 break;
166 default: GECODE_NEVER;
167 }
168 return home.ES_SUBSUMED(*this);
169 }
170
171
172 /*

Callers

nothing calls this directly

Calls 5

ES_SUBSUMEDMethod · 0.80
ES_FIX_PARTIALMethod · 0.80
equalFunction · 0.50
eqMethod · 0.45
varimpMethod · 0.45

Tested by

no test coverage detected