[libcxx-commits] [PATCH] D150896: [libc++] Apply _LIBCPP_EXCLUDE_FROM_EXPLICIT_INSTANTIATION only in classes that we have instantiated externally

Louis Dionne via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Mon May 22 18:02:48 PDT 2023


ldionne added inline comments.


================
Comment at: libcxx/include/__config:621-622
 //
 // Note that we use _LIBCPP_EXCLUDE_FROM_EXPLICIT_INSTANTIATION to ensure that we don't depend
 // on _LIBCPP_HIDE_FROM_ABI methods of classes explicitly instantiated in the dynamic library.
 //
----------------
ldionne wrote:
> This needs to be updated.
I would actually move it above to document `_LIBCPP_EXCLUDE_FROM_EXPLICIT_INSTANTIATION` and say something like:

```
// _LIBCPP_EXCLUDE_FROM_EXPLICIT_INSTANTIATION is used on methods of explicitly instantiated
// classes that we don't want to make part of the ABI to opt those methods out of the explicit instantiation
// and avoid exporting them from the dylib or relying on their definition being in the dylib.
```


================
Comment at: libcxx/utils/libcxx/test/params.py:35
   # just noise since we are testing the Standard Library itself.
   '-Wno-literal-suffix', # GCC
   '-Wno-user-defined-literals', # Clang
----------------
Can you document how you checked that there were no additional (hidden) symbols generated inside the dylib in the commit message?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D150896/new/

https://reviews.llvm.org/D150896



More information about the libcxx-commits mailing list