The attached code does various things with a type ("inv") that increments a
count on constructor calls and decrements on destructor calls. As there are no
declarations of this type, only temporaries, the net should be zero at the end
of each statement. Unfortunately, the count goes negative.

Ivan


-- 
           Summary: Destructor called twice
           Product: gcc
           Version: 3.4.4
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: igodard at pacbell dot net


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

Reply via email to