[Bug c++/14140] Unwanted call to derived constructor after implicit conversion

giovannibajo at libero dot it gcc-bugzilla@gcc.gnu.org
Sat Feb 28 14:52:00 GMT 2004


------- Additional Comments From giovannibajo at libero dot it  2004-02-28 14:52 -------
I don't see any reason why the derived copy constructor should be called. I 
also double-checked with MSVC71 and Comeau 4.3.3 (which uses the latest EDG), 
and they both agree that only the base constructor should be called. 

It looks like the conversion operator is responsible for this behaviour, and 
calls the copy constructor withour realizing the operator* returns the same 
type.

Can anybody check if this is a regression? I don't have anything older than 3.2 
(and yes, I should really rebuild those).

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
      Known to fail|                            |3.3.3 3.2.3 3.4.0 3.5.0


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14140



More information about the Gcc-bugs mailing list