Since GCC 4.0.0 the compiler issues a hosed error message for the following invalid code snippet:
====================================== struct A { virtual void foo(); void bar() { if (foo()) ; } }; ====================================== The error message reads: bug.cc: In member function 'void A::bar()': bug.cc:4: error: could not convert '#'obj_type_ref' not supported by dump_expr#<expression error>(this)' to 'bool' With GCC 3.4.4 I get bug.cc: In member function `void A::bar()': bug.cc:4: error: could not convert `(**((A*)this)->A::_vptr.A)(((A*)this))' to `bool' which is better, but not optimal. -- Summary: [4.0/4.1 regression] '#'obj_type_ref' not supported by dump_expr Product: gcc Version: 4.1.0 Status: UNCONFIRMED Keywords: diagnostic, monitored Severity: normal Priority: P2 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: reichelt at gcc dot gnu dot org CC: gcc-bugs at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=22238