llvm-project/libcxx/docs/DesignDocs
Shoaib Meenai bda3c7df78 [libc++] Make _LIBCPP_TYPE_VIS export members
Summary:
Most classes annotated with _LIBCPP_TYPE_VIS need to have at least some
of their members exported, otherwise we have a lot of link errors when
linking against a libc++ built with hidden visibility. This also makes
_LIBCPP_TYPE_VIS be consistent across platforms, since on Windows it
already exports members.

With this change made, any template methods of a class marked
_LIBCPP_TYPE_VIS will also get default visibility when instantiatied,
which is not desirable for clients of libc++ headers who wish to control
their visibility; this is the same issue as PR30642. Annotate all
problematic methods with an explicit visibility specifier to avoid this.

The problematic methods were found by running bad-visibility-finder [1]
against the libc++ headers after making the _LIBCPP_TYPE_VIS change. The
small methods were marked for inlining; the larger ones hidden.

[1] https://github.com/smeenai/bad-visibility-finder

Reviewers: mclow.lists, EricWF

Subscribers: cfe-commits

Differential Revision: https://reviews.llvm.org/D25208

llvm-svn: 296732
2017-03-02 03:22:18 +00:00
..
ABIVersioning.rst Use __config_site when building libc++. Also cleanup ABI versioning doc 2015-10-14 00:22:05 +00:00
CapturingConfigInfo.rst
DebugMode.rst Fix typo in docs 2017-02-05 01:16:25 +00:00
ThreadingSupportAPI.rst [libcxx] Improve design documentation for the external-thread-library 2017-01-16 12:44:08 +00:00
VisibilityMacros.rst [libc++] Make _LIBCPP_TYPE_VIS export members 2017-03-02 03:22:18 +00:00