This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/21405] Template inlines have global visibility
- From: "mike at navi dot cx" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 6 May 2005 00:17:49 -0000
- Subject: [Bug c++/21405] Template inlines have global visibility
- References: <20050505214934.21405.mike@navi.cx>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From mike at navi dot cx 2005-05-06 00:17 -------
No, there is very definitely a bug here even if it's just in the documentation.
The GCC docs say in very clear and unambiguous terms that this will work, by
design. Not by accident, by design. That's the whole point of applying symbol
versions to the standard C++ library.
It only affects methods that have been inlined into the headers. Methods that
are defined as external work correctly. So either:
a) No methods should be inlined
or
b) GCC should not emit them as GLOBAL WEAK so they can be overridden by other
definitions elsewhere in the image
The latter is what the new -fvisibility-inlines-hidden switch does. So why is it
not on by default?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21405