namespace { extern "C" int shouldIbevisible() { return 101; } }
extern "C" int Iamvisible() { return 101; } Is shouldIbevisible supposed to be a visible symbol outside of the current compilation unit, so that other cu that does say extern "C" int shouldIbevisible(); int foo () { return shouldIbevisible(); } would link with it? If yes, we need to change determine_visibility and push_namespace_with_attribs to take DECL_EXTERN_C_FUNCTION_P into account. -- Summary: extern "C" and anonymous namespace Product: gcc Version: 4.2.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: jakub at redhat dot com http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28409