https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81587

--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
(In reply to Martin Liška from comment #1)
> These are declarations of nested functions, you're not using them. 

Actually they are not nested functions but rather considered part of the
namespace that the function is enclosed in.  That is they reference functions
that are part of that namespace.  Like:

Assuming C++:
int f(void){return 1;}

int g(void)
{
  int f(int);  // Here f refers to ::f(int)
  return f(1);  // Here f refers to ::f(int) rather than the above function
::f(void);
}

---- CUT ----
This is valid and well defined code if int f(int); is defined in a different
translation unit.

Now GCC should warn about this code but that is a different issue.

Reply via email to