Skip to content

Commit d256e68

Browse files
committed
reverted one change to see if unit tests are now successful
1 parent cd4b984 commit d256e68

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

Population.cpp

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1533,11 +1533,17 @@ void Population::clean(void)
15331533
int ninds = (int)inds.size();
15341534
if (ninds > 0) {
15351535
inds.erase(std::remove(inds.begin(), inds.end(), (Individual *)NULL), inds.end());
1536-
#ifdef RS_RCPP || NDEBUG
1536+
#if RS_RCPP
1537+
shuffle(inds.begin(), inds.end(), pRandom->getRNG());
1538+
#else
1539+
1540+
#ifdef NDEBUG
15371541
// do not randomise individuals in DEBUG mode, as the function uses rand()
15381542
// and therefore the randomisation will differ between identical runs of RS
15391543
shuffle(inds.begin(), inds.end(), pRandom->getRNG());
1540-
#endif
1544+
#endif // NDEBUG
1545+
1546+
#endif // RS_RCPP
15411547
}
15421548
}
15431549

0 commit comments

Comments
 (0)