This patch: http://gcc.gnu.org/ml/gcc-patches/2009-10/msg00782.html
Introduces some compile time diagnostics: - static_assert(__m == 0 || (__a < __m && __c < __m), - "template arguments out of bounds" - " in linear_congruential_engine"); + static_assert(std::is_unsigned<_UIntType>::value, "template argument " + "_UIntType not an unsigned integral type"); + static_assert(__m == 0u || (__a < __m && __c < __m), + "template argument __m out of bounds"); Walter Brown has suggested for positive, not negative phrasing on diagnostics, and indicated that some improvement may be possible. Details are a little fuzzy, but this is a placeholder for that conversation. If we do this for random, then there are other C++0x areas where we could also do this, maybe the atomic bits? -- Summary: [C++0x] <random> static_assert phrasing should be positive Product: gcc Version: 4.5.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: libstdc++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: bkoz at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41759