
Hi Gareth, On Wed, 28 Apr 2010 08:58 +0100, "Sylvester-Bradley, Gareth" <Gareth.Sylvester-Bradley@eu.sony.com> wrote:
http://beta.boost.org/doc/libs/1_42_0/libs/uuid/uuid.html#POD%20Efficien cies includes some example code for making a uuid_class from the struct uuid POD.
I was confused to see the example uuid_class both derives from boost::uuids::uuid *and* provides operator boost::uuids::uuid() [const].
Aren't the conversion operators unnecessary, as a conversion function is never called to convert an object to a base class of that type (by 12.3.2 [class.conv.fct])?
In fact the source file that the documentation references (e.g. at https://svn.boost.org/trac/boost/browser/tags/release/Boost_1_43_0_beta1 /libs/uuid/test/test_uuid_class.cpp) doesn't include the conversion operators. I think the documentation should be updated to match.
Thanks very much. You are correct. The class does not need the conversion operators. I will update the documentation.
Cheers, Gareth
Regards, Andy.