This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
binds_local question
- From: Mike Stump <mrs at apple dot com>
- To: "gcc at gcc dot gnu dot org List" <gcc at gcc dot gnu dot org>
- Date: Mon, 30 Aug 2004 17:12:56 -0700
- Subject: binds_local question
In varasm.c we have:
/* A variable is local if the user explicitly tells us so. */
else if (DECL_VISIBILITY_SPECIFIED (exp) && DECL_VISIBILITY (exp) !=
VISIBILITY_DEFAULT)
local_p = true;
/* Otherwise, variables defined outside this object may not be local.
*/
else if (DECL_EXTERNAL (exp))
local_p = false;
I was wondering if a variable that was marked with a visibility for
documentation purposes in a header file that was external, should be
considered local or not. I'd expect that it would not be local, but
for that to be true, the two lines above would have to be swapped.
? Any downside to swapping them?
Construct found in some darwin header files.