[Random] compiler issue with Visual Studio
Hello,
I am using Visual Studio 7.1.3008. While using the Random library, I
ran into an issue with the seed function of mt19937. From what I can
gather, the compiler becomes confused about one of the overloads and
tries to call the seed function:
template<class Generator>
void seed(Generator & gen)
I couldn't this issue on the list of known issues for this compiler. Is
this known. For now, it appears that the work-around is to cast it as
an unsigned long.
Below is a small test file that demonstrates this issue.
Thank you,
David Walthall
////// boost_random_error.cpp //////
#include
I am using Visual Studio 7.1.3008. While using the Random library, I ran into an issue with the seed function of mt19937. From what I can gather, the compiler becomes confused about one of the overloads and tries to call the seed function: template<class Generator> void seed(Generator & gen)
I couldn't this issue on the list of known issues for this compiler. Is this known. For now, it appears that the work-around is to cast it as an unsigned long.
Yep, it's a bug in the library I believe. It's not much consolation, but if you use the std::tr1:: version in Boost-1.34 when it arrives you won't have this problem. John.
participants (2)
-
David Walthall
-
John Maddock