This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/40192] [4.4/4.5 Regression] Unable to use std::vector with typedef'd array types



------- Comment #7 from jeff at schwabcenter dot com  2009-05-19 17:09 -------
I understand the desire for backward compatibility, but are the semantics
actually the same?  Are the vector values arrays, or do they decay to pointers?
 Section 23.1 says standard container elements have to be CopyConstructible and
assignable, but raw arrays are neither.

Is there at least some flag to re-enable the diagnostic?  If you're saying this
is a necessary evil for reasons of backward compatibility, then I understand,
but in my opinion, this is a step backward that will confuse newcomers like
Brian and hurt cross-compatibility.  Speaking strictly as a GCC user, I don't
see any reason to reduce the compiler's ability to deduce an obvious mistake
with ill-defined semantics.


-- 


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]