Jim Ingram wrote:
Some more information:
I'm using gcc 4.0.2 on Ubuntu, with the latest available version of Boost (for Ubuntu anyway. It's 1.32.0+1.33.0-cvs20050727). That's the version from Ubuntu Breezy, 1.33.1 is in Dapper.
I'm writing a class that is supposed to simulate a six-sided die. It compiles and everything works, except seeding the mt19937. Every time I try testing this class, I get the same numbers, no matter what value I call my seed method with. The problem is that 'variate_generator' stores a copy of the engine, not a reference. So this works:
#include