This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

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.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]