6 Nov
2017
6 Nov
'17
4:10 p.m.
AMDG On 11/06/2017 07:21 AM, James E. King, III via Boost wrote:
I'm not certain that it is necessary to make random_generator a separate class like this. As it is, I have removed most of the additional weight from basic_random_generator like the variate and uniform code. I'll turn the crank one more time however to see if I can make any further improvements.
uniform_int_distribution is not excess weight. You could use independent_bits_engine instead, but if you accept an arbitrary random engine, then you need some way to convert its output into the correct range. Not all engines produce uniformly distributed 32-bit output. In Christ, Steven Watanabe