This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: another binutils-2.8.1 bug?
- To: hjl at lucon dot org
- Subject: Re: another binutils-2.8.1 bug?
- From: Paul Eggert <eggert at twinsun dot com>
- Date: Sat, 10 Jan 1998 22:27:06 -0800
- CC: tm at netcom dot com, gcc2 at cygnus dot com, egcs at cygnus dot com
- References: <m0xr8it-0004ecC@ocean.lucon.org>
From: hjl@lucon.org (H.J. Lu)
Date: Sat, 10 Jan 1998 13:45:43 -0800 (PST)
> Evidently, if you change a static function into a non-static function,
> but the static prototype is left floating around, GCC converts the
> function to a static automatically, which seems rather dangerous.
I don't know what ANSI C says on it.
ANSI C requires that behavior.
It might be nice if GCC warned about the situation, but I don't think
it's dangerous all that often. All that happens is that the function
is unexpectedly static, which normally just leads to a link error.