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

Method post

gecode/int/bool/eq.hpp:59–80  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

57
58 template<class BVA, class BVB>
59 inline ExecStatus
60 Eq<BVA,BVB>::post(Home home, BVA b0, BVB b1) {
61 switch (bool_test(b0,b1)) {
62 case BT_SAME: return ES_OK;
63 case BT_COMP: return ES_FAILED;
64 case BT_NONE:
65 if (b0.zero()) {
66 GECODE_ME_CHECK(b1.zero(home));
67 } else if (b0.one()) {
68 GECODE_ME_CHECK(b1.one(home));
69 } else if (b1.zero()) {
70 GECODE_ME_CHECK(b0.zero(home));
71 } else if (b1.one()) {
72 GECODE_ME_CHECK(b0.one(home));
73 } else {
74 (void) new (home) Eq<BVA,BVB>(home,b0,b1);
75 }
76 break;
77 default: GECODE_NEVER;
78 }
79 return ES_OK;
80 }
81
82 template<class BVA, class BVB>
83 ExecStatus

Callers

nothing calls this directly

Calls 9

bool_testFunction · 0.85
postFunction · 0.50
zeroMethod · 0.45
oneMethod · 0.45
uniqueMethod · 0.45
sizeMethod · 0.45
assignedMethod · 0.45
one_noneMethod · 0.45
zero_noneMethod · 0.45

Tested by

no test coverage detected