Perform commit for choice \a _c and alternative \a a
| 428 | } |
| 429 | /// Perform commit for choice \a _c and alternative \a a |
| 430 | virtual ExecStatus commit(Space& home, const Gecode::Choice& _c, |
| 431 | unsigned int a) { |
| 432 | SteelMill& sm = static_cast<SteelMill&>(home); |
| 433 | const Choice& c = static_cast<const Choice&>(_c); |
| 434 | if (a) |
| 435 | return me_failed(Int::IntView(sm.slab[c.pos]).nq(home, c.val)) |
| 436 | ? ES_FAILED : ES_OK; |
| 437 | else |
| 438 | return me_failed(Int::IntView(sm.slab[c.pos]).eq(home, c.val)) |
| 439 | ? ES_FAILED : ES_OK; |
| 440 | } |
| 441 | /// Print explanation |
| 442 | virtual void print(const Space&, const Gecode::Choice& _c, |
| 443 | unsigned int a, |