On 13 February 2014 20:47, Patrick Palka wrote:
> On a related note, would a patch to officially enable
> -Wmissing-declarations in the build process be well regarded?

What would be the advantage?

>  Since
> -Wmissing-prototypes is currently enabled, I assume it is the
> intention of the GCC devs to address these warnings, and that during
> the transition from a C to C++ bootstrap compiler a small oversight
> was made (that -Wmissing-prototypes is a no-op against C++ source
> files).

The additional safety provided by -Wmissing-prototypes is already
guaranteed for C++.

In C a missing prototype causes the compiler to guess, probably
incorrectly, how to call the function.

In C++ a function cannot be called without a previous declaration and
the linker will notice if you declare a function with one signature
and define it differently.

Reply via email to