[Bug c++/60860] New: Friend function declaration incorrectly hides function in outer namespace
dibeas at ieee dot org
gcc-bugzilla@gcc.gnu.org
Wed Apr 16 13:38:00 GMT 2014
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60860
Bug ID: 60860
Summary: Friend function declaration incorrectly hides function
in outer namespace
Product: gcc
Version: 4.8.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: dibeas at ieee dot org
The following valid code fails to compile:
void f( int );
namespace N {
struct A
{
friend void f(int);
friend void f(double);
};
void g() {
f(0);
}
}
The problem goes away if any of the two friend declarations is commented out.
More information about the Gcc-bugs
mailing list