Boost logo

Boost Users :

From: Nick Toze geeky_nick_at_[hidden])
Date: 2003-01-15 11:16:37


Hello,

I had a slight problem compiling random_demo.cpp after I had changed
the typedef to: typedef boost::mt19937 base_generator_type;

I got this error:

--------------------Configuration: random_demo - Win32
Debug--------------------
Compiling...
random_demo.cpp
d:\c_plus_plus\boost_1_29_0\boost\random\mersenne_twister.hpp(104) :
error C2064: term does not evaluate to a function
       
d:\c_plus_plus\boost_1_29_0\boost\random\mersenne_twister.hpp(75) :
see reference to function template instantiation 'void __thiscall
boost::random::mersenne_twister<unsigned
long,624,397,31,-1727483681,11,7,-1658038656,15,-272236544,18,-948
541730>::seed(const unsigned int &)' being compiled
Error executing cl.exe.
Creating browse info file...

random_demo.exe - 1 error(s), 0 warning(s)

I fixed it by adding an 'L' to the first line of main, i.e.
base_generator_type generator(42Lu);


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net