diff --git a/src/Random.cpp b/src/Random.cpp index 2906ccc7..a4c55a7a 100644 --- a/src/Random.cpp +++ b/src/Random.cpp @@ -60,7 +60,7 @@ void Random::prop_sample_bucket( // all probabilities are the same if (heavy == n) { - for (auto i = 0; i < size; ++i) { + for (size_t i = 0; i < size; ++i) { *result = (*rng)((uint64_t)n); ++result; } @@ -121,9 +121,9 @@ void Random::prop_sample_bucket( } // sample - for (auto i = 0; i < size; ++i) { + for (size_t i = 0; i < size; ++i) { size_t bucket = (*rng)((uint64_t)n); - double acceptance = dqrng::uniform01((*rng)()); + double acceptance = rng->uniform01(); *result = (acceptance < dividing_probs[bucket]) ? bucket : alternative_index[bucket]; ++result;