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++/70991] Uninitialized class allowed if it came from self-assignment, or a member function


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

--- Comment #2 from bennet brauer <appfault at hotmail dot com> ---
By the way, this bug mentions classes specifically, because the same idea but
with a simple "int" assignment generates a warning:

error: âfooâ is used uninitialized in this function [-Werror=uninitialized]
int foo = foo;           // Unintialized direct assignment.
          ^

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