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++/14560] New: pseudo-destructor-name type-name mismatch is incorrectly diagnosed and reported in cases where there is no mismatch


As far as I know the code presented here should compile without problems.
Rationale: [5.2.4] and [3.4.3]/5. The test case is a minor modification
of the example from [3.4.3]/5. In case of scalar types the check should
be on the type designated by I not on the name of I.

gcc -Wall q.ii
q.cc: In function `int main()':
q.cc:10: qualified type `int' does not match destructor name `~I'

q.ii:
# 1 "q.cc"
# 1 "<built-in>"
# 1 "<command line>"
# 1 "q.cc"
struct C {
        typedef int I;
        I i;
};
typedef int I1, I2;
extern C * p;
extern C * q;
int main()
{
        p->i.C::I::~I();
        q->i.I1::~I2();
}

-- 
           Summary: pseudo-destructor-name type-name mismatch is incorrectly
                    diagnosed and reported in cases where there is no
                    mismatch
           Product: gcc
           Version: 3.2.3
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: tichm9am at ss1000 dot ms dot mff dot cuni dot cz
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: i686-pc-linux-gnu
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu


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


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