Commit ee5e5b87 authored by Lukas Weber's avatar Lukas Weber
Browse files

save seeds properly

up to now seeds were not saved to the dump file. Since the state of the
RNG was saved properly and the seed is only used in the initialization,
this likely did not affect the results.
parent 310ae8d5
......@@ -28,7 +28,12 @@ private:
return 0;
uint64_t seed_;
void set_seed(uint64_t seed) {
seed_ = seed;
static_cast<base *>(this)->set_seed(seed);
uint64_t seed_{};
rng_base() {
......@@ -36,11 +41,11 @@ public:
std::vector<uint64_t> seed(1);
seq.generate(seed.begin(), seed.end());
static_cast<base *>(this)->set_seed(seed[0]);
rng_base(uint64_t seed) {
static_cast<base *>(this)->set_seed(seed);
std::string type() const {
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment