
"Robert Ramey" <ramey@rrsd.com> wrote in message news:conqf6$hnh$1@sea.gmane.org...
The documentation for has_trivial_constructor has some cryptic note: Without some (as yet unspecified) help from the compiler, has_trivial_constructor will never report that a class or struct has a trivial constructor; this is always safe, if possibly sub-optimal.
What does this mean - it sounds like its of new use - then why is it there?
Certain compilers provide special information about types that can't be queried in std C++. The type traits library uses this, where possible, but always provides a conservative fallback answer. See <boost/type_traits/intrinsics.hpp> TR1 contains similar language, but the hope (I think) is that C++0x will contain enough compile-time reflection to allow these traits to be implemented 'optimally' in standard C++0x. Jonathan