When I compile this C++ file with current mainline:
class c { ~c(); };
namespace m { c::~c() { } }
I get this error message:
foo.cc:2: error: definition of void c::c() is not in namespace enclosing c
This error is wrong: the definition in the wrong place is for c::~c(), not
c::c().
--
Summary: Incorrect error message for destructor in wrong
namespace
Product: gcc
Version: 4.2.0
Status: UNCONFIRMED
Severity: minor
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: ian at airs dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29077