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

Method assign

test/int.cpp:254–265  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

252 }
253
254 void
255 TestSpace::assign(const Assignment& a, bool skip, Gecode::Support::RandomGenerator& rand) {
256 using namespace Gecode;
257 int i = skip ?
258 static_cast<int>(rand(static_cast<unsigned int>(a.size()))) : -1;
259 for (int j=a.size(); j--; )
260 if (i != j) {
261 rel(j, IRT_EQ, a[j]);
262 if (Base::fixpoint(rand) && failed())
263 return;
264 }
265 }
266
267 void
268 TestSpace::bound(Gecode::Support::RandomGenerator& rand) {

Callers 1

runMethod · 0.45

Calls 2

relFunction · 0.50
sizeMethod · 0.45

Tested by

no test coverage detected