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

Method fixprob

test/set.cpp:340–371  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

338 }
339
340 bool
341 SetTestSpace::fixprob(void) {
342 if (failed())
343 return true;
344 SetTestSpace* c = static_cast<SetTestSpace*>(clone());
345 if (opt.log)
346 olog << ind(3) << "Testing fixpoint on copy" << std::endl;
347 c->post();
348 if (c->failed()) {
349 delete c; return false;
350 }
351
352 for (int i=x.size(); i--; )
353 if (x[i].glbSize() != c->x[i].glbSize() ||
354 x[i].lubSize() != c->x[i].lubSize() ||
355 x[i].cardMin() != c->x[i].cardMin() ||
356 x[i].cardMax() != c->x[i].cardMax()) {
357 delete c;
358 return false;
359 }
360 for (int i=y.size(); i--; )
361 if (y[i].size() != c->y[i].size()) {
362 delete c; return false;
363 }
364 if (reified && (r.var().size() != c->r.var().size())) {
365 delete c; return false;
366 }
367 if (opt.log)
368 olog << ind(3) << "Finished testing fixpoint on copy" << std::endl;
369 delete c;
370 return true;
371 }
372
373 bool
374 SetTestSpace::same(SetTestSpace& c) {

Callers

nothing calls this directly

Calls 9

indClass · 0.85
postMethod · 0.45
failedMethod · 0.45
sizeMethod · 0.45
glbSizeMethod · 0.45
lubSizeMethod · 0.45
cardMinMethod · 0.45
cardMaxMethod · 0.45
varMethod · 0.45

Tested by

no test coverage detected