This is the mail archive of the gcc-prs@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]

Re: c++/6322: Multiple inheritance structure causes segfault on delete.


Synopsis: Multiple inheritance structure causes segfault on delete.

State-Changed-From-To: open->closed
State-Changed-By: nathan
State-Changed-When: Thu Apr 25 07:19:33 2002
State-Changed-Why:
    not a bug. your code is ill-formed.
    you are attempting to delete a derived object using a
    pointer to one of its bases. Refer to [5.3.5].
    In particular, if the static type of the object (base in
    your case) is different to the dynamic type (derived),
    the static type shall be a base of the dynamic type (ok),
    and the static type shall have a virtual destructor, otherwise
    the behaviour is undefined.

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=6322


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