20 Jul
2007
20 Jul
'07
9:10 a.m.
Hi,
From the documentation I think this should be possible:
optional<unsigned short> us; optional<unsigned int> ui; ui = us; In this case it should just leave ui uninitialized. But instead I hit the assertion in reference_const_type get() const, because there is a call to rhs.get() in the operator=(). Is this a bug, or am I doing something wrong? I'm using MSVC7.1. Best regards, Christian Larsen