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]

Re: RFC: C++: __attribute__((visibility)) for classes


On May 19, 2004, at 12:13 PM, Gabriel Dos Reis wrote:

Matt Austern <austern@apple.com> writes:

[...]

| I believe that any sensible solution has to be in the compiler.
| Asking users to explicitly list the symbols they want to hind is
| unreasonable: ordinary users shouldn't have to know which classes will
| need VTTs, construction vtables, and the like, and certainly shouldn't
| have to know the mangled names for those ghastly things. Even your
| average guru would probably get it wrong most of the time. I'm sure I
| would.


A question:  Why would those symbols be "exported" in the first place?
If I understand correctly, they are emitted in the translation unit
that contains the key-method, wouldn't it make sense to have them
local to that translation unit?

I don't see how they could be. That's the translation unit where they're defined, but in the general case there are undefined references from other translation units.

--Matt


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