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++/71885] Incorrect code generated with -01, memset() function call is missing


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71885

hyc at symas dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |hyc at symas dot com

--- Comment #14 from hyc at symas dot com ---
(In reply to Markus Trippelsdorf from comment #8)
> See Initializers 8.6.12:  
> 
> When storage for an object with automatic or dynamic storage duration is
> obtained, the object has an indeterminate value, and if no initialization is
> performed for the object, that object retains an indeterminate value until
> that value is replaced (5.17).

"If no initialization is performed" - this is the constructor, whose job is to
create and initialize the object, and you're preventing that initialization
from happening. How is that logical?

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