mirror of
https://github.com/llvm-mirror/libcxx.git
synced 2025-10-21 23:30:38 +08:00
[libc++] Introduce _LIBCPP_EXTERN_VIS to fix __libcpp_debug_function link errors
Summary: On Windows tests that use `_LIBCPP_ASSERT` fail to link because the assertion handler function isn't correctly exported from the libc++ dylib. This patch fixes the dll import/export issues by introducing a new visibility macro `_LIBCPP_EXTERN_VIS` for use on external variables. Reviewers: compnerd, smeenai, EricWF Reviewed By: EricWF Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D28728 git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@292158 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -22,6 +22,12 @@ Visibility Macros
|
||||
Mark a symbol as being exported by the libc++ library. This attribute must
|
||||
be applied to the declaration of all functions exported by the libc++ dylib.
|
||||
|
||||
**_LIBCPP_EXTERN_VIS**
|
||||
Mark a symbol as being exported by the libc++ library. This attribute may
|
||||
only be applied to objects defined in the libc++ library. On Windows this
|
||||
macro applies `dllimport`/`dllexport` to the symbol. On all other platforms
|
||||
this macro has no effect.
|
||||
|
||||
**_LIBCPP_OVERRIDABLE_FUNC_VIS**
|
||||
Mark a symbol as being exported by the libc++ library, but allow it to be
|
||||
overridden locally. On non-Windows, this is equivalent to `_LIBCPP_FUNC_VIS`.
|
||||
|
Reference in New Issue
Block a user