[Bug c++/78749] New: [7 Regression] bogus warning for friend member function in anonymous namespace
trippels at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Fri Dec 9 11:06:00 GMT 2016
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78749
Bug ID: 78749
Summary: [7 Regression] bogus warning for friend member
function in anonymous namespace
Product: gcc
Version: 7.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: trippels at gcc dot gnu.org
Target Milestone: ---
% cat t.ii
namespace {
template <typename> struct A {
friend void foo() {}
};
struct C : A<int> {};
}
% g++ -Wall -c t.ii
MallocChecker.ii:3:15: warning: ‘void {anonymous}::foo()’ declared ‘static’ but
never defined [-Wunused-function]
friend void foo() {}
^~~
More information about the Gcc-bugs
mailing list