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++/21279] New: static Derived-to-Base cast fails when ~Derived has run.


In this test case, I cast a Derived* to a Base* after the destructor for the
Derived part has run. It's a strange thing to do, but I think the cast should
succeed, because it does not need instance information.

It only seems to happen when using virtual inheritance. We noticed this in
libsigc++.

-- 
           Summary: static Derived-to-Base cast fails when ~Derived has run.
           Product: gcc
           Version: 4.0.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: murrayc at murrayc dot com
                CC: gcc-bugs at gcc dot gnu dot org


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


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