[libc++] Add hide_from_abi check for classes
authorNikolas Klauser <nikolasklauser@berlin.de>
Mon, 23 Jan 2023 09:27:14 +0000 (10:27 +0100)
committerNikolas Klauser <nikolasklauser@berlin.de>
Sun, 16 Apr 2023 13:23:23 +0000 (15:23 +0200)
We already have a clang-tidy check for making sure that `_LIBCPP_HIDE_FROM_ABI` is on free functions. This patch extends this to class members. The places where we don't check for `_LIBCPP_HIDE_FROM_ABI` are classes for which we have an instantiation in the library.

Reviewed By: ldionne, Mordante, #libc

Spies: jplehr, mikhail.ramalho, sstefan1, libcxx-commits, krytarowski, miyuki, smeenai

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

111 files changed:
libcxx/include/__algorithm/comp_ref_type.h
libcxx/include/__algorithm/make_projected.h
libcxx/include/__algorithm/shuffle.h
libcxx/include/__atomic/atomic_flag.h
libcxx/include/__chrono/calendar.h
libcxx/include/__chrono/day.h
libcxx/include/__chrono/duration.h
libcxx/include/__chrono/month.h
libcxx/include/__chrono/monthday.h
libcxx/include/__chrono/weekday.h
libcxx/include/__chrono/year.h
libcxx/include/__chrono/year_month.h
libcxx/include/__chrono/year_month_day.h
libcxx/include/__chrono/year_month_weekday.h
libcxx/include/__concepts/swappable.h
libcxx/include/__condition_variable/condition_variable.h
libcxx/include/__coroutine/coroutine_handle.h
libcxx/include/__expected/bad_expected_access.h
libcxx/include/__expected/unexpect.h
libcxx/include/__filesystem/directory_entry.h
libcxx/include/__filesystem/file_status.h
libcxx/include/__filesystem/filesystem_error.h
libcxx/include/__filesystem/path_iterator.h
libcxx/include/__filesystem/recursive_directory_iterator.h
libcxx/include/__format/format_args.h
libcxx/include/__functional/boyer_moore_searcher.h
libcxx/include/__functional/function.h
libcxx/include/__functional/hash.h
libcxx/include/__functional/identity.h
libcxx/include/__functional/invoke.h
libcxx/include/__functional/perfect_forward.h
libcxx/include/__functional/ranges_operations.h
libcxx/include/__hash_table
libcxx/include/__iterator/common_iterator.h
libcxx/include/__iterator/move_sentinel.h
libcxx/include/__locale
libcxx/include/__memory/allocator.h
libcxx/include/__memory/builtin_new_allocator.h
libcxx/include/__memory/ranges_uninitialized_algorithms.h
libcxx/include/__memory/shared_ptr.h
libcxx/include/__memory/temp_value.h
libcxx/include/__memory_resource/monotonic_buffer_resource.h
libcxx/include/__memory_resource/polymorphic_allocator.h
libcxx/include/__memory_resource/synchronized_pool_resource.h
libcxx/include/__mutex/mutex.h
libcxx/include/__random/binomial_distribution.h
libcxx/include/__random/discard_block_engine.h
libcxx/include/__random/discrete_distribution.h
libcxx/include/__random/exponential_distribution.h
libcxx/include/__random/extreme_value_distribution.h
libcxx/include/__random/fisher_f_distribution.h
libcxx/include/__random/gamma_distribution.h
libcxx/include/__random/independent_bits_engine.h
libcxx/include/__random/linear_congruential_engine.h
libcxx/include/__random/mersenne_twister_engine.h
libcxx/include/__random/negative_binomial_distribution.h
libcxx/include/__random/normal_distribution.h
libcxx/include/__random/piecewise_constant_distribution.h
libcxx/include/__random/piecewise_linear_distribution.h
libcxx/include/__random/poisson_distribution.h
libcxx/include/__random/random_device.h
libcxx/include/__random/seed_seq.h
libcxx/include/__random/student_t_distribution.h
libcxx/include/__random/subtract_with_carry_engine.h
libcxx/include/__random/uniform_int_distribution.h
libcxx/include/__random/uniform_real_distribution.h
libcxx/include/__ranges/drop_view.h
libcxx/include/__ranges/iota_view.h
libcxx/include/__ranges/non_propagating_cache.h
libcxx/include/__ranges/owning_view.h
libcxx/include/__ranges/range_adaptor.h
libcxx/include/__ranges/subrange.h
libcxx/include/__string/char_traits.h
libcxx/include/__system_error/system_error.h
libcxx/include/__tree
libcxx/include/__tuple/sfinae_helpers.h
libcxx/include/__utility/in_place.h
libcxx/include/__utility/pair.h
libcxx/include/any
libcxx/include/array
libcxx/include/barrier
libcxx/include/condition_variable
libcxx/include/experimental/iterator
libcxx/include/experimental/memory_resource
libcxx/include/experimental/propagate_const
libcxx/include/experimental/simd
libcxx/include/ext/hash_map
libcxx/include/ext/hash_set
libcxx/include/forward_list
libcxx/include/fstream
libcxx/include/future
libcxx/include/ios
libcxx/include/latch
libcxx/include/list
libcxx/include/locale
libcxx/include/map
libcxx/include/optional
libcxx/include/regex
libcxx/include/scoped_allocator
libcxx/include/set
libcxx/include/shared_mutex
libcxx/include/stdexcept
libcxx/include/strstream
libcxx/include/thread
libcxx/include/tuple
libcxx/include/typeinfo
libcxx/include/unordered_map
libcxx/include/unordered_set
libcxx/include/variant
libcxx/include/vector
libcxx/test/tools/clang_tidy_checks/hide_from_abi.cpp

index f2338e1..55c5ce8 100644 (file)
@@ -23,11 +23,10 @@ template <class _Compare>
 struct __debug_less
 {
     _Compare &__comp_;
-    _LIBCPP_CONSTEXPR_SINCE_CXX14
-    __debug_less(_Compare& __c) : __comp_(__c) {}
+    _LIBCPP_CONSTEXPR_SINCE_CXX14 _LIBCPP_HIDE_FROM_ABI __debug_less(_Compare& __c) : __comp_(__c) {}
 
     template <class _Tp, class _Up>
-    _LIBCPP_CONSTEXPR_SINCE_CXX14
+    _LIBCPP_CONSTEXPR_SINCE_CXX14 _LIBCPP_HIDE_FROM_ABI
     bool operator()(const _Tp& __x,  const _Up& __y)
     {
         bool __r = __comp_(__x, __y);
@@ -37,7 +36,7 @@ struct __debug_less
     }
 
     template <class _Tp, class _Up>
-    _LIBCPP_CONSTEXPR_SINCE_CXX14
+    _LIBCPP_CONSTEXPR_SINCE_CXX14 _LIBCPP_HIDE_FROM_ABI
     bool operator()(_Tp& __x,  _Up& __y)
     {
         bool __r = __comp_(__x, __y);
index defda46..ec85476 100644 (file)
@@ -32,13 +32,14 @@ struct _ProjectedPred {
   _Pred& __pred; // Can be a unary or a binary predicate.
   _Proj& __proj;
 
-  _LIBCPP_CONSTEXPR _ProjectedPred(_Pred& __pred_arg, _Proj& __proj_arg) : __pred(__pred_arg), __proj(__proj_arg) {}
+  _LIBCPP_CONSTEXPR _LIBCPP_HIDE_FROM_ABI _ProjectedPred(_Pred& __pred_arg, _Proj& __proj_arg)
+      : __pred(__pred_arg), __proj(__proj_arg) {}
 
   template <class _Tp>
   typename __invoke_of<_Pred&,
                        decltype(std::__invoke(std::declval<_Proj&>(), std::declval<_Tp>()))
   >::type
-  _LIBCPP_CONSTEXPR operator()(_Tp&& __v) const {
+  _LIBCPP_CONSTEXPR _LIBCPP_HIDE_FROM_ABI operator()(_Tp&& __v) const {
     return std::__invoke(__pred, std::__invoke(__proj, std::forward<_Tp>(__v)));
   }
 
@@ -47,7 +48,7 @@ struct _ProjectedPred {
                        decltype(std::__invoke(std::declval<_Proj&>(), std::declval<_T1>())),
                        decltype(std::__invoke(std::declval<_Proj&>(), std::declval<_T2>()))
   >::type
-  _LIBCPP_CONSTEXPR operator()(_T1&& __lhs, _T2&& __rhs) const {
+  _LIBCPP_CONSTEXPR _LIBCPP_HIDE_FROM_ABI operator()(_T1&& __lhs, _T2&& __rhs) const {
     return std::__invoke(__pred,
                       std::__invoke(__proj, std::forward<_T1>(__lhs)),
                       std::__invoke(__proj, std::forward<_T2>(__rhs)));
index f7bce68..d6cc340 100644 (file)
@@ -31,7 +31,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD
 
 class _LIBCPP_TYPE_VIS __libcpp_debug_randomizer {
 public:
-  __libcpp_debug_randomizer() {
+  _LIBCPP_HIDE_FROM_ABI __libcpp_debug_randomizer() {
     __state_ = __seed();
     __inc_ = __state_ + 0xda3e39cb94b95bdbULL;
     __inc_ = (__inc_ << 1) | 1;
@@ -85,8 +85,8 @@ public:
 
     result_type operator()();
 
-    static _LIBCPP_CONSTEXPR result_type min() {return _Min;}
-    static _LIBCPP_CONSTEXPR result_type max() {return _Max;}
+    static _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR result_type min() {return _Min;}
+    static _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR result_type max() {return _Max;}
 
     friend _LIBCPP_FUNC_VIS __rs_default __rs_get();
 };
index 46a6ad7..edfa978 100644 (file)
@@ -71,7 +71,6 @@ struct atomic_flag
     _LIBCPP_HIDE_FROM_ABI constexpr
     atomic_flag() _NOEXCEPT : __a_(false) {}
 #else
-    _LIBCPP_HIDE_FROM_ABI
     atomic_flag() _NOEXCEPT = default;
 #endif
 
index e14f96d..94b5e31 100644 (file)
@@ -31,7 +31,7 @@ using local_time  = time_point<local_t, Duration>;
 using local_seconds = local_time<seconds>;
 using local_days    = local_time<days>;
 
-struct last_spec { _LIBCPP_HIDE_FROM_ABI explicit last_spec() = default; };
+struct last_spec { explicit last_spec() = default; };
 inline constexpr last_spec last{};
 
 
index 13a885c..c907c03 100644 (file)
@@ -29,7 +29,7 @@ class day {
 private:
     unsigned char __d_;
 public:
-    _LIBCPP_HIDE_FROM_ABI day() = default;
+    day() = default;
     _LIBCPP_HIDE_FROM_ABI explicit inline constexpr day(unsigned __val) noexcept : __d_(static_cast<unsigned char>(__val)) {}
     _LIBCPP_HIDE_FROM_ABI inline constexpr day& operator++()    noexcept { ++__d_; return *this; }
     _LIBCPP_HIDE_FROM_ABI inline constexpr day  operator++(int) noexcept { day __tmp = *this; ++(*this); return __tmp; }
index 2c8d50a..96e9671 100644 (file)
@@ -244,11 +244,10 @@ private:
     rep __rep_;
 public:
 
-    _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR
 #ifndef _LIBCPP_CXX03_LANG
-        duration() = default;
+        constexpr duration() = default;
 #else
-        duration() {}
+        _LIBCPP_HIDE_FROM_ABI duration() {}
 #endif
 
     template <class _Rep2>
index ad679e4..5dff7ce 100644 (file)
@@ -29,7 +29,7 @@ class month {
 private:
     unsigned char __m_;
 public:
-    _LIBCPP_HIDE_FROM_ABI month() = default;
+    month() = default;
     _LIBCPP_HIDE_FROM_ABI explicit inline constexpr month(unsigned __val) noexcept : __m_(static_cast<unsigned char>(__val)) {}
     _LIBCPP_HIDE_FROM_ABI inline constexpr month& operator++()    noexcept { ++__m_; return *this; }
     _LIBCPP_HIDE_FROM_ABI inline constexpr month  operator++(int) noexcept { month __tmp = *this; ++(*this); return __tmp; }
index 961b71e..03fd750 100644 (file)
@@ -32,7 +32,7 @@ private:
    chrono::month __m_;
    chrono::day   __d_;
 public:
-    _LIBCPP_HIDE_FROM_ABI month_day() = default;
+    month_day() = default;
     _LIBCPP_HIDE_FROM_ABI constexpr month_day(const chrono::month& __mval, const chrono::day& __dval) noexcept
         : __m_{__mval}, __d_{__dval} {}
     _LIBCPP_HIDE_FROM_ABI inline constexpr chrono::month month() const noexcept { return __m_; }
index ed9530f..84b4a38 100644 (file)
@@ -35,7 +35,7 @@ private:
     unsigned char __wd_;
     _LIBCPP_HIDE_FROM_ABI static constexpr unsigned char __weekday_from_days(int __days) noexcept;
 public:
-  _LIBCPP_HIDE_FROM_ABI weekday() = default;
+  weekday() = default;
   _LIBCPP_HIDE_FROM_ABI inline explicit constexpr weekday(unsigned __val) noexcept : __wd_(static_cast<unsigned char>(__val == 7 ? 0 : __val)) {}
   _LIBCPP_HIDE_FROM_ABI inline constexpr          weekday(const sys_days& __sysd) noexcept
           : __wd_(__weekday_from_days(__sysd.time_since_epoch().count())) {}
@@ -126,7 +126,7 @@ private:
     chrono::weekday __wd_;
     unsigned char   __idx_;
 public:
-    _LIBCPP_HIDE_FROM_ABI weekday_indexed() = default;
+    weekday_indexed() = default;
     _LIBCPP_HIDE_FROM_ABI inline constexpr weekday_indexed(const chrono::weekday& __wdval, unsigned __idxval) noexcept
         : __wd_{__wdval}, __idx_(__idxval) {}
     _LIBCPP_HIDE_FROM_ABI inline constexpr chrono::weekday weekday() const noexcept { return __wd_; }
index d5251aa..14bcbda 100644 (file)
@@ -33,7 +33,7 @@ class year {
 private:
     short __y_;
 public:
-    _LIBCPP_HIDE_FROM_ABI year() = default;
+    year() = default;
     _LIBCPP_HIDE_FROM_ABI explicit inline constexpr year(int __val) noexcept : __y_(static_cast<short>(__val)) {}
 
     _LIBCPP_HIDE_FROM_ABI inline constexpr year& operator++()    noexcept { ++__y_; return *this; }
index 7a6acff..f4eea84 100644 (file)
@@ -31,7 +31,7 @@ class year_month {
     chrono::year  __y_;
     chrono::month __m_;
 public:
-    _LIBCPP_HIDE_FROM_ABI year_month() = default;
+    year_month() = default;
     _LIBCPP_HIDE_FROM_ABI constexpr year_month(const chrono::year& __yval, const chrono::month& __mval) noexcept
         : __y_{__yval}, __m_{__mval} {}
     _LIBCPP_HIDE_FROM_ABI inline constexpr chrono::year  year()  const noexcept { return __y_; }
index 4d64db3..ed5903f 100644 (file)
@@ -42,7 +42,7 @@ private:
     chrono::month __m_;
     chrono::day   __d_;
 public:
-     _LIBCPP_HIDE_FROM_ABI year_month_day() = default;
+     year_month_day() = default;
      _LIBCPP_HIDE_FROM_ABI inline constexpr year_month_day(
             const chrono::year& __yval, const chrono::month& __mval, const chrono::day& __dval) noexcept
             : __y_{__yval}, __m_{__mval}, __d_{__dval} {}
index b667120..28de10c 100644 (file)
@@ -39,7 +39,7 @@ class year_month_weekday {
     chrono::month           __m_;
     chrono::weekday_indexed __wdi_;
 public:
-    _LIBCPP_HIDE_FROM_ABI year_month_weekday() = default;
+    year_month_weekday() = default;
     _LIBCPP_HIDE_FROM_ABI constexpr year_month_weekday(const chrono::year& __yval, const chrono::month& __mval,
                                const chrono::weekday_indexed& __wdival) noexcept
         : __y_{__yval}, __m_{__mval}, __wdi_{__wdival} {}
index 340691d..859255d 100644 (file)
@@ -68,7 +68,7 @@ namespace __swap {
     // *The name `swap` is used here unqualified.
     template<class _Tp, class _Up>
       requires __unqualified_swappable_with<_Tp, _Up>
-    constexpr void operator()(_Tp&& __t, _Up&& __u) const
+    _LIBCPP_HIDE_FROM_ABI constexpr void operator()(_Tp&& __t, _Up&& __u) const
       noexcept(noexcept(swap(_VSTD::forward<_Tp>(__t), _VSTD::forward<_Up>(__u))))
     {
       swap(_VSTD::forward<_Tp>(__t), _VSTD::forward<_Up>(__u));
@@ -77,7 +77,7 @@ namespace __swap {
     // 2.2   Otherwise, if `E1` and `E2` are lvalues of array types with equal extent and...
     template<class _Tp, class _Up, size_t _Size>
       requires __swappable_arrays<_Tp, _Up, _Size>
-    constexpr void operator()(_Tp(& __t)[_Size], _Up(& __u)[_Size]) const
+    _LIBCPP_HIDE_FROM_ABI constexpr void operator()(_Tp(& __t)[_Size], _Up(& __u)[_Size]) const
       noexcept(noexcept((*this)(*__t, *__u)))
     {
       // TODO(cjdb): replace with `ranges::swap_ranges`.
@@ -88,7 +88,7 @@ namespace __swap {
 
     // 2.3   Otherwise, if `E1` and `E2` are lvalues of the same type `T` that models...
     template<__exchangeable _Tp>
-    constexpr void operator()(_Tp& __x, _Tp& __y) const
+    _LIBCPP_HIDE_FROM_ABI constexpr void operator()(_Tp& __x, _Tp& __y) const
       noexcept(is_nothrow_move_constructible_v<_Tp> && is_nothrow_move_assignable_v<_Tp>)
     {
       __y = _VSTD::exchange(__x, _VSTD::move(__y));
index 10b0662..8fc80b6 100644 (file)
@@ -82,11 +82,12 @@ private:
   void
   __do_timed_wait(unique_lock<mutex>& __lk, chrono::time_point<chrono::system_clock, chrono::nanoseconds>) _NOEXCEPT;
 #  if defined(_LIBCPP_HAS_COND_CLOCKWAIT)
-  void
+  _LIBCPP_HIDE_FROM_ABI void
   __do_timed_wait(unique_lock<mutex>& __lk, chrono::time_point<chrono::steady_clock, chrono::nanoseconds>) _NOEXCEPT;
 #  endif
   template <class _Clock>
-  void __do_timed_wait(unique_lock<mutex>& __lk, chrono::time_point<_Clock, chrono::nanoseconds>) _NOEXCEPT;
+  _LIBCPP_HIDE_FROM_ABI void
+  __do_timed_wait(unique_lock<mutex>& __lk, chrono::time_point<_Clock, chrono::nanoseconds>) _NOEXCEPT;
 };
 #endif // !_LIBCPP_HAS_NO_THREADS
 
index 8390b49..2135111 100644 (file)
@@ -33,7 +33,6 @@ template <>
 struct _LIBCPP_TEMPLATE_VIS coroutine_handle<void> {
 public:
     // [coroutine.handle.con], construct/reset
-    _LIBCPP_HIDE_FROM_ABI
     constexpr coroutine_handle() noexcept = default;
 
     _LIBCPP_HIDE_FROM_ABI
@@ -86,7 +85,7 @@ public:
     }
 
 private:
-    bool __is_suspended() const {
+    _LIBCPP_HIDE_FROM_ABI bool __is_suspended() const {
         // FIXME actually implement a check for if the coro is suspended.
         return __handle_ != nullptr;
     }
@@ -108,7 +107,6 @@ template <class _Promise>
 struct _LIBCPP_TEMPLATE_VIS coroutine_handle {
 public:
     // [coroutine.handle.con], construct/reset
-    _LIBCPP_HIDE_FROM_ABI
     constexpr coroutine_handle() noexcept = default;
 
     _LIBCPP_HIDE_FROM_ABI
@@ -182,7 +180,7 @@ public:
     }
 
 private:
-    bool __is_suspended() const {
+    _LIBCPP_HIDE_FROM_ABI bool __is_suspended() const {
         // FIXME actually implement a check for if the coro is suspended.
         return __handle_ != nullptr;
     }
index e7a568c..1b88ab2 100644 (file)
@@ -32,14 +32,14 @@ protected:
   _LIBCPP_HIDE_FROM_ABI bad_expected_access(bad_expected_access&&)                 = default;
   _LIBCPP_HIDE_FROM_ABI bad_expected_access& operator=(const bad_expected_access&) = default;
   _LIBCPP_HIDE_FROM_ABI bad_expected_access& operator=(bad_expected_access&&)      = default;
-  ~bad_expected_access() override                                                  = default;
+  _LIBCPP_HIDE_FROM_ABI_VIRTUAL ~bad_expected_access() override                    = default;
 
 public:
   // The way this has been designed (by using a class template below) means that we'll already
   // have a profusion of these vtables in TUs, and the dynamic linker will already have a bunch
   // of work to do. So it is not worth hiding the <void> specialization in the dylib, given that
   // it adds deployment target restrictions.
-  const char* what() const noexcept override { return "bad access to std::expected"; }
+  _LIBCPP_HIDE_FROM_ABI_VIRTUAL const char* what() const noexcept override { return "bad access to std::expected"; }
 };
 
 template <class _Err>
index 20bafc1..df52787 100644 (file)
@@ -20,7 +20,7 @@
 _LIBCPP_BEGIN_NAMESPACE_STD
 
 struct unexpect_t {
-  _LIBCPP_HIDE_FROM_ABI explicit unexpect_t() = default;
+  explicit unexpect_t() = default;
 };
 
 inline constexpr unexpect_t unexpect{};
index 111dcbd..bd9dbdc 100644 (file)
@@ -47,9 +47,9 @@ class directory_entry {
 
 public:
   // constructors and destructors
-  directory_entry() noexcept = default;
-  directory_entry(directory_entry const&) = default;
-  directory_entry(directory_entry&&) noexcept = default;
+  _LIBCPP_HIDE_FROM_ABI directory_entry() noexcept = default;
+  _LIBCPP_HIDE_FROM_ABI directory_entry(directory_entry const&) = default;
+  _LIBCPP_HIDE_FROM_ABI directory_entry(directory_entry&&) noexcept = default;
 
   _LIBCPP_INLINE_VISIBILITY
   explicit directory_entry(_Path const& __p) : __p_(__p) {
@@ -62,10 +62,10 @@ public:
     __refresh(&__ec);
   }
 
-  ~directory_entry() {}
+  _LIBCPP_HIDE_FROM_ABI ~directory_entry() {}
 
-  directory_entry& operator=(directory_entry const&) = default;
-  directory_entry& operator=(directory_entry&&) noexcept = default;
+  _LIBCPP_HIDE_FROM_ABI directory_entry& operator=(directory_entry const&) = default;
+  _LIBCPP_HIDE_FROM_ABI directory_entry& operator=(directory_entry&&) noexcept = default;
 
   _LIBCPP_INLINE_VISIBILITY
   void assign(_Path const& __p) {
@@ -511,8 +511,8 @@ public:
 private:
   friend class directory_iterator;
   friend class recursive_directory_iterator;
-  explicit __dir_element_proxy(directory_entry const& __e) : __elem_(__e) {}
-  __dir_element_proxy(__dir_element_proxy&& __o)
+  _LIBCPP_HIDE_FROM_ABI explicit __dir_element_proxy(directory_entry const& __e) : __elem_(__e) {}
+  _LIBCPP_HIDE_FROM_ABI __dir_element_proxy(__dir_element_proxy&& __o)
       : __elem_(_VSTD::move(__o.__elem_)) {}
   directory_entry __elem_;
 };
index ac3f6cb..350b0fc 100644 (file)
@@ -35,14 +35,14 @@ public:
       : __ft_(__ft),
         __prms_(__prms) {}
 
-  file_status(const file_status&) noexcept = default;
-  file_status(file_status&&) noexcept = default;
+  _LIBCPP_HIDE_FROM_ABI file_status(const file_status&) noexcept = default;
+  _LIBCPP_HIDE_FROM_ABI file_status(file_status&&) noexcept = default;
 
   _LIBCPP_INLINE_VISIBILITY
   ~file_status() {}
 
-  file_status& operator=(const file_status&) noexcept = default;
-  file_status& operator=(file_status&&) noexcept = default;
+  _LIBCPP_HIDE_FROM_ABI file_status& operator=(const file_status&) noexcept = default;
+  _LIBCPP_HIDE_FROM_ABI file_status& operator=(file_status&&) noexcept = default;
 
   // observers
   _LIBCPP_INLINE_VISIBILITY
index 7860fc4..d345dab 100644 (file)
@@ -60,7 +60,7 @@ public:
   _LIBCPP_INLINE_VISIBILITY
   const path& path2() const noexcept { return __storage_->__p2_; }
 
-  filesystem_error(const filesystem_error&) = default;
+  _LIBCPP_HIDE_FROM_ABI filesystem_error(const filesystem_error&) = default;
   ~filesystem_error() override; // key function
 
   _LIBCPP_HIDE_FROM_ABI_VIRTUAL
index 6f2baf8..d754fdc 100644 (file)
@@ -56,10 +56,10 @@ public:
       : __stashed_elem_(), __path_ptr_(nullptr), __entry_(),
         __state_(_Singular) {}
 
-  iterator(const iterator&) = default;
-  ~iterator() = default;
+  _LIBCPP_HIDE_FROM_ABI iterator(const iterator&) = default;
+  _LIBCPP_HIDE_FROM_ABI ~iterator() = default;
 
-  iterator& operator=(const iterator&) = default;
+  _LIBCPP_HIDE_FROM_ABI iterator& operator=(const iterator&) = default;
 
   _LIBCPP_INLINE_VISIBILITY
   reference operator*() const { return __stashed_elem_; }
index ac40dc8..3d5c025 100644 (file)
@@ -60,10 +60,10 @@ public:
   recursive_directory_iterator(const path& __p, error_code& __ec)
       : recursive_directory_iterator(__p, directory_options::none, &__ec) {}
 
-  recursive_directory_iterator(const recursive_directory_iterator&) = default;
-  recursive_directory_iterator(recursive_directory_iterator&&) = default;
+  _LIBCPP_HIDE_FROM_ABI recursive_directory_iterator(const recursive_directory_iterator&) = default;
+  _LIBCPP_HIDE_FROM_ABI recursive_directory_iterator(recursive_directory_iterator&&) = default;
 
-  recursive_directory_iterator&
+  _LIBCPP_HIDE_FROM_ABI recursive_directory_iterator&
   operator=(const recursive_directory_iterator&) = default;
 
   _LIBCPP_INLINE_VISIBILITY
@@ -77,7 +77,7 @@ public:
     return *this;
   }
 
-  ~recursive_directory_iterator() = default;
+  _LIBCPP_HIDE_FROM_ABI ~recursive_directory_iterator() = default;
 
   _LIBCPP_INLINE_VISIBILITY
   const directory_entry& operator*() const { return __dereference(); }
@@ -85,7 +85,7 @@ public:
   _LIBCPP_INLINE_VISIBILITY
   const directory_entry* operator->() const { return &__dereference(); }
 
-  recursive_directory_iterator& operator++() { return __increment(); }
+  _LIBCPP_HIDE_FROM_ABI recursive_directory_iterator& operator++() { return __increment(); }
 
   _LIBCPP_INLINE_VISIBILITY
   __dir_element_proxy operator++(int) {
index c2e7c96..defb42a 100644 (file)
@@ -29,7 +29,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD
 template <class _Context>
 class _LIBCPP_TEMPLATE_VIS basic_format_args {
 public:
-  _LIBCPP_HIDE_FROM_ABI basic_format_args() noexcept = default;
+  basic_format_args() noexcept = default;
 
   template <class... _Args>
   _LIBCPP_HIDE_FROM_ABI basic_format_args(const __format_arg_store<_Context, _Args...>& __store) noexcept
index 1e2d861..d5384e9 100644 (file)
@@ -113,6 +113,7 @@ private:
                                       && is_same_v<_BinaryPredicate, equal_to<>>>;
 
 public:
+  _LIBCPP_HIDE_FROM_ABI
   boyer_moore_searcher(_RandomAccessIterator1 __first,
                        _RandomAccessIterator1 __last,
                        _Hash __hash = _Hash(),
@@ -134,7 +135,7 @@ public:
   }
 
   template <class _RandomAccessIterator2>
-  pair<_RandomAccessIterator2, _RandomAccessIterator2>
+  _LIBCPP_HIDE_FROM_ABI pair<_RandomAccessIterator2, _RandomAccessIterator2>
   operator()(_RandomAccessIterator2 __first, _RandomAccessIterator2 __last) const {
     static_assert(__is_same_uncvref<typename iterator_traits<_RandomAccessIterator1>::value_type,
                                     typename iterator_traits<_RandomAccessIterator2>::value_type>::value,
@@ -158,7 +159,7 @@ private:
   shared_ptr<difference_type[]> __suffix_;
 
   template <class _RandomAccessIterator2>
-  pair<_RandomAccessIterator2, _RandomAccessIterator2>
+  _LIBCPP_HIDE_FROM_ABI pair<_RandomAccessIterator2, _RandomAccessIterator2>
   __search(_RandomAccessIterator2 __f, _RandomAccessIterator2 __l) const {
     _RandomAccessIterator2 __current = __f;
     const _RandomAccessIterator2 __last = __l - __pattern_length_;
@@ -183,7 +184,8 @@ private:
   }
 
   template <class _Iterator, class _Container>
-  void __compute_bm_prefix(_Iterator __first, _Iterator __last, _BinaryPredicate __pred, _Container& __prefix) {
+  _LIBCPP_HIDE_FROM_ABI void
+  __compute_bm_prefix(_Iterator __first, _Iterator __last, _BinaryPredicate __pred, _Container& __prefix) {
     const size_t __count = __last - __first;
 
     __prefix[0] = 0;
@@ -199,7 +201,8 @@ private:
     }
   }
 
-  void __build_suffix_table(_RandomAccessIterator1 __first, _RandomAccessIterator1 __last, _BinaryPredicate __pred) {
+  _LIBCPP_HIDE_FROM_ABI void
+  __build_suffix_table(_RandomAccessIterator1 __first, _RandomAccessIterator1 __last, _BinaryPredicate __pred) {
     const size_t __count = __last - __first;
 
     if (__count == 0)
@@ -241,6 +244,7 @@ private:
                                       && is_same_v<_Hash, hash<value_type>>
                                       && is_same_v<_BinaryPredicate, equal_to<>>>;
 public:
+  _LIBCPP_HIDE_FROM_ABI
   boyer_moore_horspool_searcher(_RandomAccessIterator1 __first,
                                 _RandomAccessIterator1 __last,
                                 _Hash __hash = _Hash(),
@@ -262,7 +266,7 @@ public:
   }
 
   template <class _RandomAccessIterator2>
-  pair<_RandomAccessIterator2, _RandomAccessIterator2>
+  _LIBCPP_HIDE_FROM_ABI pair<_RandomAccessIterator2, _RandomAccessIterator2>
   operator()(_RandomAccessIterator2 __first, _RandomAccessIterator2 __last) const {
     static_assert(__is_same_uncvref<typename std::iterator_traits<_RandomAccessIterator1>::value_type,
                                     typename std::iterator_traits<_RandomAccessIterator2>::value_type>::value,
@@ -286,7 +290,7 @@ private:
   shared_ptr<__skip_table_type> __skip_table_;
 
   template <class _RandomAccessIterator2>
-  pair<_RandomAccessIterator2, _RandomAccessIterator2>
+  _LIBCPP_HIDE_FROM_ABI pair<_RandomAccessIterator2, _RandomAccessIterator2>
   __search(_RandomAccessIterator2 __f, _RandomAccessIterator2 __l) const {
     _RandomAccessIterator2 __current = __f;
     const _RandomAccessIterator2 __last = __l - __pattern_length_;
index 70ae6d1..1f94d79 100644 (file)
@@ -59,7 +59,7 @@ public:
 #ifdef _LIBCPP_ABI_BAD_FUNCTION_CALL_KEY_FUNCTION
     ~bad_function_call() _NOEXCEPT override;
 #else
-    ~bad_function_call() _NOEXCEPT override {}
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL ~bad_function_call() _NOEXCEPT override {}
 #endif
 
 #ifdef _LIBCPP_ABI_BAD_FUNCTION_CALL_GOOD_WHAT_MESSAGE
@@ -204,7 +204,7 @@ class __alloc_func<_Fp, _Ap, _Rp(_ArgTypes...)>
     _LIBCPP_INLINE_VISIBILITY
     void destroy() _NOEXCEPT { __f_.~__compressed_pair<_Target, _Alloc>(); }
 
-    static void __destroy_and_delete(__alloc_func* __f) {
+    _LIBCPP_HIDE_FROM_ABI static void __destroy_and_delete(__alloc_func* __f) {
       typedef allocator_traits<_Alloc> __alloc_traits;
       typedef __rebind_alloc<__alloc_traits, __alloc_func> _FunAlloc;
       _FunAlloc __a(__f->__get_allocator());
@@ -248,7 +248,7 @@ public:
   _LIBCPP_INLINE_VISIBILITY
   void destroy() _NOEXCEPT { __f_.~_Target(); }
 
-  static void __destroy_and_delete(__default_alloc_func* __f) {
+  _LIBCPP_HIDE_FROM_ABI static void __destroy_and_delete(__default_alloc_func* __f) {
     __f->destroy();
       __builtin_new_allocator::__deallocate_type<__default_alloc_func>(__f, 1);
   }
@@ -303,14 +303,14 @@ public:
     explicit __func(_Fp&& __f, _Alloc&& __a)
         : __f_(_VSTD::move(__f), _VSTD::move(__a)) {}
 
-    virtual __base<_Rp(_ArgTypes...)>* __clone() const;
-    virtual void __clone(__base<_Rp(_ArgTypes...)>*) const;
-    virtual void destroy() _NOEXCEPT;
-    virtual void destroy_deallocate() _NOEXCEPT;
-    virtual _Rp operator()(_ArgTypes&&... __arg);
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual __base<_Rp(_ArgTypes...)>* __clone() const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __clone(__base<_Rp(_ArgTypes...)>*) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void destroy() _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void destroy_deallocate() _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual _Rp operator()(_ArgTypes&&... __arg);
 #ifndef _LIBCPP_HAS_NO_RTTI
-    virtual const void* target(const type_info&) const _NOEXCEPT;
-    virtual const std::type_info& target_type() const _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual const void* target(const type_info&) const _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual const std::type_info& target_type() const _NOEXCEPT;
 #endif // _LIBCPP_HAS_NO_RTTI
 };
 
@@ -392,7 +392,7 @@ template <class _Rp, class... _ArgTypes> class __value_func<_Rp(_ArgTypes...)>
     typedef __base<_Rp(_ArgTypes...)> __func;
     __func* __f_;
 
-    _LIBCPP_NO_CFI static __func* __as_base(void* __p)
+    _LIBCPP_HIDE_FROM_ABI _LIBCPP_NO_CFI static __func* __as_base(void* __p)
     {
         return reinterpret_cast<__func*>(__p);
     }
@@ -629,14 +629,15 @@ struct __policy
     }
 
   private:
-    template <typename _Fun> static void* __large_clone(const void* __s)
+    template <typename _Fun>
+    _LIBCPP_HIDE_FROM_ABI static void* __large_clone(const void* __s)
     {
         const _Fun* __f = static_cast<const _Fun*>(__s);
         return __f->__clone();
     }
 
     template <typename _Fun>
-    static void __large_destroy(void* __s) {
+    _LIBCPP_HIDE_FROM_ABI static void __large_destroy(void* __s) {
       _Fun::__destroy_and_delete(static_cast<_Fun*>(__s));
     }
 
@@ -702,14 +703,14 @@ struct __policy_invoker<_Rp(_ArgTypes...)>
     _LIBCPP_INLINE_VISIBILITY
     explicit __policy_invoker(__Call __c) : __call_(__c) {}
 
-    static _Rp __call_empty(const __policy_storage*,
+    _LIBCPP_HIDE_FROM_ABI static _Rp __call_empty(const __policy_storage*,
                             __fast_forward<_ArgTypes>...)
     {
         __throw_bad_function_call();
     }
 
     template <typename _Fun>
-    static _Rp __call_impl(const __policy_storage* __buf,
+    _LIBCPP_HIDE_FROM_ABI static _Rp __call_impl(const __policy_storage* __buf,
                            __fast_forward<_ArgTypes>... __args)
     {
         _Fun* __f = reinterpret_cast<_Fun*>(__use_small_storage<_Fun>::value
@@ -1005,11 +1006,11 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     function() _NOEXCEPT { }
     _LIBCPP_INLINE_VISIBILITY
-    function(nullptr_t) _NOEXCEPT {}
-    function(const function&);
-    function(function&&) _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI function(nullptr_t) _NOEXCEPT {}
+    _LIBCPP_HIDE_FROM_ABI function(const function&);
+    _LIBCPP_HIDE_FROM_ABI function(function&&) _NOEXCEPT;
     template<class _Fp, class = _EnableIfLValueCallable<_Fp>>
-    function(_Fp);
+    _LIBCPP_HIDE_FROM_ABI function(_Fp);
 
 #if _LIBCPP_STD_VER <= 14
     template<class _Alloc>
@@ -1019,23 +1020,23 @@ public:
       _LIBCPP_INLINE_VISIBILITY
       function(allocator_arg_t, const _Alloc&, nullptr_t) _NOEXCEPT {}
     template<class _Alloc>
-      function(allocator_arg_t, const _Alloc&, const function&);
+    _LIBCPP_HIDE_FROM_ABI function(allocator_arg_t, const _Alloc&, const function&);
     template<class _Alloc>
-      function(allocator_arg_t, const _Alloc&, function&&);
+    _LIBCPP_HIDE_FROM_ABI function(allocator_arg_t, const _Alloc&, function&&);
     template<class _Fp, class _Alloc, class = _EnableIfLValueCallable<_Fp>>
-      function(allocator_arg_t, const _Alloc& __a, _Fp __f);
+    _LIBCPP_HIDE_FROM_ABI function(allocator_arg_t, const _Alloc& __a, _Fp __f);
 #endif
 
-    function& operator=(const function&);
-    function& operator=(function&&) _NOEXCEPT;
-    function& operator=(nullptr_t) _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI function& operator=(const function&);
+    _LIBCPP_HIDE_FROM_ABI function& operator=(function&&) _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI function& operator=(nullptr_t) _NOEXCEPT;
     template<class _Fp, class = _EnableIfLValueCallable<__decay_t<_Fp>>>
-    function& operator=(_Fp&&);
+    _LIBCPP_HIDE_FROM_ABI function& operator=(_Fp&&);
 
-    ~function();
+    _LIBCPP_HIDE_FROM_ABI ~function();
 
     // function modifiers:
-    void swap(function&) _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI void swap(function&) _NOEXCEPT;
 
 #if _LIBCPP_STD_VER <= 14
     template<class _Fp, class _Alloc>
@@ -1057,13 +1058,15 @@ public:
       bool operator!=(const function<_R2(_ArgTypes2...)>&) const = delete;
 public:
     // function invocation:
-    _Rp operator()(_ArgTypes...) const;
+    _LIBCPP_HIDE_FROM_ABI _Rp operator()(_ArgTypes...) const;
 
 #ifndef _LIBCPP_HAS_NO_RTTI
     // function target access:
-    const std::type_info& target_type() const _NOEXCEPT;
-    template <typename _Tp> _Tp* target() _NOEXCEPT;
-    template <typename _Tp> const _Tp* target() const _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI const std::type_info& target_type() const _NOEXCEPT;
+    template <typename _Tp>
+    _LIBCPP_HIDE_FROM_ABI _Tp* target() _NOEXCEPT;
+    template <typename _Tp>
+    _LIBCPP_HIDE_FROM_ABI const _Tp* target() const _NOEXCEPT;
 #endif // _LIBCPP_HAS_NO_RTTI
 };
 
index fec7f75..fa09748 100644 (file)
@@ -136,12 +136,12 @@ struct __murmur2_or_cityhash<_Size, 64>
         __hash_len_16(__v.second, __w.second) + __x);
   }
 
- private:
-  // Some primes between 2^63 and 2^64.
-  static const _Size __k0 = 0xc3a5c85c97cb3127ULL;
-  static const _Size __k1 = 0xb492b66fbe98f273ULL;
-  static const _Size __k2 = 0x9ae16a3b2f90404fULL;
-  static const _Size __k3 = 0xc949d7c7509e6557ULL;
 private:
+    // Some primes between 2^63 and 2^64.
+    static const _Size __k0 = 0xc3a5c85c97cb3127ULL;
+    static const _Size __k1 = 0xb492b66fbe98f273ULL;
+    static const _Size __k2 = 0x9ae16a3b2f90404fULL;
+    static const _Size __k3 = 0xc949d7c7509e6557ULL;
 
   _LIBCPP_HIDE_FROM_ABI
   static _Size __rotate(_Size __val, int __shift) {
index 421ba2f..5dffedf 100644 (file)
@@ -25,7 +25,7 @@ struct __is_identity : false_type {};
 
 struct __identity {
   template <class _Tp>
-  _LIBCPP_NODISCARD _LIBCPP_CONSTEXPR _Tp&& operator()(_Tp&& __t) const _NOEXCEPT {
+  _LIBCPP_NODISCARD _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR _Tp&& operator()(_Tp&& __t) const _NOEXCEPT {
     return std::forward<_Tp>(__t);
   }
 
@@ -39,7 +39,7 @@ struct __is_identity<__identity> : true_type {};
 
 struct identity {
     template<class _Tp>
-    _LIBCPP_NODISCARD_EXT constexpr _Tp&& operator()(_Tp&& __t) const noexcept
+    _LIBCPP_NODISCARD_EXT _LIBCPP_HIDE_FROM_ABI constexpr _Tp&& operator()(_Tp&& __t) const noexcept
     {
         return _VSTD::forward<_Tp>(__t);
     }
index 82fd18d..c490684 100644 (file)
@@ -474,7 +474,7 @@ template <class _Ret, bool = is_void<_Ret>::value>
 struct __invoke_void_return_wrapper
 {
     template <class ..._Args>
-    static _Ret __call(_Args&&... __args) {
+    _LIBCPP_HIDE_FROM_ABI static _Ret __call(_Args&&... __args) {
         return std::__invoke(std::forward<_Args>(__args)...);
     }
 };
@@ -483,7 +483,7 @@ template <class _Ret>
 struct __invoke_void_return_wrapper<_Ret, true>
 {
     template <class ..._Args>
-    static void __call(_Args&&... __args) {
+    _LIBCPP_HIDE_FROM_ABI static void __call(_Args&&... __args) {
         std::__invoke(std::forward<_Args>(__args)...);
     }
 };
index af89797..e12654c 100644 (file)
@@ -36,14 +36,14 @@ public:
   template <class... _Args, class = enable_if_t<
     is_constructible_v<tuple<_BoundArgs...>, _Args&&...>
   >>
-  explicit constexpr __perfect_forward_impl(_Args&&... __bound_args)
+  _LIBCPP_HIDE_FROM_ABI explicit constexpr __perfect_forward_impl(_Args&&... __bound_args)
     : __bound_args_(_VSTD::forward<_Args>(__bound_args)...) {}
 
-  __perfect_forward_impl(__perfect_forward_impl const&) = default;
-  __perfect_forward_impl(__perfect_forward_impl&&) = default;
+  _LIBCPP_HIDE_FROM_ABI __perfect_forward_impl(__perfect_forward_impl const&) = default;
+  _LIBCPP_HIDE_FROM_ABI __perfect_forward_impl(__perfect_forward_impl&&) = default;
 
-  __perfect_forward_impl& operator=(__perfect_forward_impl const&) = default;
-  __perfect_forward_impl& operator=(__perfect_forward_impl&&) = default;
+  _LIBCPP_HIDE_FROM_ABI __perfect_forward_impl& operator=(__perfect_forward_impl const&) = default;
+  _LIBCPP_HIDE_FROM_ABI __perfect_forward_impl& operator=(__perfect_forward_impl&&) = default;
 
   template <class... _Args, class = enable_if_t<is_invocable_v<_Op, _BoundArgs&..., _Args...>>>
   _LIBCPP_HIDE_FROM_ABI constexpr auto operator()(_Args&&... __args) &
index 77b6a6d..c344fc3 100644 (file)
@@ -30,7 +30,7 @@ namespace ranges {
 struct equal_to {
   template <class _Tp, class _Up>
   requires equality_comparable_with<_Tp, _Up>
-  [[nodiscard]] constexpr bool operator()(_Tp &&__t, _Up &&__u) const
+  [[nodiscard]] _LIBCPP_HIDE_FROM_ABI constexpr bool operator()(_Tp &&__t, _Up &&__u) const
       noexcept(noexcept(bool(_VSTD::forward<_Tp>(__t) == _VSTD::forward<_Up>(__u)))) {
     return _VSTD::forward<_Tp>(__t) == _VSTD::forward<_Up>(__u);
   }
@@ -41,7 +41,7 @@ struct equal_to {
 struct not_equal_to {
   template <class _Tp, class _Up>
   requires equality_comparable_with<_Tp, _Up>
-  [[nodiscard]] constexpr bool operator()(_Tp &&__t, _Up &&__u) const
+  [[nodiscard]] _LIBCPP_HIDE_FROM_ABI constexpr bool operator()(_Tp &&__t, _Up &&__u) const
       noexcept(noexcept(bool(!(_VSTD::forward<_Tp>(__t) == _VSTD::forward<_Up>(__u))))) {
     return !(_VSTD::forward<_Tp>(__t) == _VSTD::forward<_Up>(__u));
   }
@@ -52,7 +52,7 @@ struct not_equal_to {
 struct less {
   template <class _Tp, class _Up>
   requires totally_ordered_with<_Tp, _Up>
-  [[nodiscard]] constexpr bool operator()(_Tp &&__t, _Up &&__u) const
+  [[nodiscard]] _LIBCPP_HIDE_FROM_ABI constexpr bool operator()(_Tp &&__t, _Up &&__u) const
       noexcept(noexcept(bool(_VSTD::forward<_Tp>(__t) < _VSTD::forward<_Up>(__u)))) {
     return _VSTD::forward<_Tp>(__t) < _VSTD::forward<_Up>(__u);
   }
@@ -63,7 +63,7 @@ struct less {
 struct less_equal {
   template <class _Tp, class _Up>
   requires totally_ordered_with<_Tp, _Up>
-  [[nodiscard]] constexpr bool operator()(_Tp &&__t, _Up &&__u) const
+  [[nodiscard]] _LIBCPP_HIDE_FROM_ABI constexpr bool operator()(_Tp &&__t, _Up &&__u) const
       noexcept(noexcept(bool(!(_VSTD::forward<_Up>(__u) < _VSTD::forward<_Tp>(__t))))) {
     return !(_VSTD::forward<_Up>(__u) < _VSTD::forward<_Tp>(__t));
   }
@@ -74,7 +74,7 @@ struct less_equal {
 struct greater {
   template <class _Tp, class _Up>
   requires totally_ordered_with<_Tp, _Up>
-  [[nodiscard]] constexpr bool operator()(_Tp &&__t, _Up &&__u) const
+  [[nodiscard]] _LIBCPP_HIDE_FROM_ABI constexpr bool operator()(_Tp &&__t, _Up &&__u) const
       noexcept(noexcept(bool(_VSTD::forward<_Up>(__u) < _VSTD::forward<_Tp>(__t)))) {
     return _VSTD::forward<_Up>(__u) < _VSTD::forward<_Tp>(__t);
   }
@@ -85,7 +85,7 @@ struct greater {
 struct greater_equal {
   template <class _Tp, class _Up>
   requires totally_ordered_with<_Tp, _Up>
-  [[nodiscard]] constexpr bool operator()(_Tp &&__t, _Up &&__u) const
+  [[nodiscard]] _LIBCPP_HIDE_FROM_ABI constexpr bool operator()(_Tp &&__t, _Up &&__u) const
       noexcept(noexcept(bool(!(_VSTD::forward<_Tp>(__t) < _VSTD::forward<_Up>(__u))))) {
     return !(_VSTD::forward<_Tp>(__t) < _VSTD::forward<_Up>(__u));
   }
index e38a442..289c772 100644 (file)
@@ -813,8 +813,8 @@ private:
 public:
     bool __value_constructed;
 
-    __hash_node_destructor(__hash_node_destructor const&) = default;
-    __hash_node_destructor& operator=(const __hash_node_destructor&) = delete;
+    _LIBCPP_HIDE_FROM_ABI __hash_node_destructor(__hash_node_destructor const&) = default;
+    _LIBCPP_HIDE_FROM_ABI __hash_node_destructor& operator=(const __hash_node_destructor&) = delete;
 
 
     _LIBCPP_INLINE_VISIBILITY
@@ -986,22 +986,22 @@ public:
             is_nothrow_default_constructible<key_equal>::value);
     _LIBCPP_INLINE_VISIBILITY
     __hash_table(const hasher& __hf, const key_equal& __eql);
-    __hash_table(const hasher& __hf, const key_equal& __eql,
+    _LIBCPP_HIDE_FROM_ABI __hash_table(const hasher& __hf, const key_equal& __eql,
                  const allocator_type& __a);
-    explicit __hash_table(const allocator_type& __a);
-    __hash_table(const __hash_table& __u);
-    __hash_table(const __hash_table& __u, const allocator_type& __a);
-    __hash_table(__hash_table&& __u)
+    _LIBCPP_HIDE_FROM_ABI explicit __hash_table(const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI __hash_table(const __hash_table& __u);
+    _LIBCPP_HIDE_FROM_ABI __hash_table(const __hash_table& __u, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI __hash_table(__hash_table&& __u)
         _NOEXCEPT_(
             is_nothrow_move_constructible<__bucket_list>::value &&
             is_nothrow_move_constructible<__first_node>::value &&
             is_nothrow_move_constructible<__node_allocator>::value &&
             is_nothrow_move_constructible<hasher>::value &&
             is_nothrow_move_constructible<key_equal>::value);
-    __hash_table(__hash_table&& __u, const allocator_type& __a);
-    ~__hash_table();
+    _LIBCPP_HIDE_FROM_ABI __hash_table(__hash_table&& __u, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI ~__hash_table();
 
-    __hash_table& operator=(const __hash_table& __u);
+    _LIBCPP_HIDE_FROM_ABI __hash_table& operator=(const __hash_table& __u);
     _LIBCPP_INLINE_VISIBILITY
     __hash_table& operator=(__hash_table&& __u)
         _NOEXCEPT_(
@@ -1010,9 +1010,9 @@ public:
             is_nothrow_move_assignable<hasher>::value &&
             is_nothrow_move_assignable<key_equal>::value);
     template <class _InputIterator>
-        void __assign_unique(_InputIterator __first, _InputIterator __last);
+    _LIBCPP_HIDE_FROM_ABI void __assign_unique(_InputIterator __first, _InputIterator __last);
     template <class _InputIterator>
-        void __assign_multi(_InputIterator __first, _InputIterator __last);
+    _LIBCPP_HIDE_FROM_ABI void __assign_multi(_InputIterator __first, _InputIterator __last);
 
     _LIBCPP_INLINE_VISIBILITY
     size_type max_size() const _NOEXCEPT
@@ -1161,7 +1161,7 @@ public:
     _NodeHandle __node_handle_extract(const_iterator __it);
 #endif
 
-    void clear() _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI void clear() _NOEXCEPT;
     _LIBCPP_INLINE_VISIBILITY void __rehash_unique(size_type __n) { __rehash<true>(__n); }
     _LIBCPP_INLINE_VISIBILITY void __rehash_multi(size_type __n) { __rehash<false>(__n); }
     _LIBCPP_INLINE_VISIBILITY void __reserve_unique(size_type __n)
@@ -1198,42 +1198,42 @@ public:
         }
 
     template <class _Key>
-        iterator       find(const _Key& __x);
+    _LIBCPP_HIDE_FROM_ABI iterator       find(const _Key& __x);
     template <class _Key>
-        const_iterator find(const _Key& __x) const;
+    _LIBCPP_HIDE_FROM_ABI const_iterator find(const _Key& __x) const;
 
     typedef __hash_node_destructor<__node_allocator> _Dp;
     typedef unique_ptr<__node, _Dp> __node_holder;
 
-    iterator erase(const_iterator __p);
-    iterator erase(const_iterator __first, const_iterator __last);
+    _LIBCPP_HIDE_FROM_ABI iterator erase(const_iterator __p);
+    _LIBCPP_HIDE_FROM_ABI iterator erase(const_iterator __first, const_iterator __last);
     template <class _Key>
-        size_type __erase_unique(const _Key& __k);
+    _LIBCPP_HIDE_FROM_ABI size_type __erase_unique(const _Key& __k);
     template <class _Key>
-        size_type __erase_multi(const _Key& __k);
-    __node_holder remove(const_iterator __p) _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI size_type __erase_multi(const _Key& __k);
+    _LIBCPP_HIDE_FROM_ABI __node_holder remove(const_iterator __p) _NOEXCEPT;
 
     template <class _Key>
         _LIBCPP_INLINE_VISIBILITY
         size_type __count_unique(const _Key& __k) const;
     template <class _Key>
-        size_type __count_multi(const _Key& __k) const;
+    _LIBCPP_HIDE_FROM_ABI size_type __count_multi(const _Key& __k) const;
 
     template <class _Key>
-        pair<iterator, iterator>
+    _LIBCPP_HIDE_FROM_ABI pair<iterator, iterator>
         __equal_range_unique(const _Key& __k);
     template <class _Key>
-        pair<const_iterator, const_iterator>
+    _LIBCPP_HIDE_FROM_ABI pair<const_iterator, const_iterator>
         __equal_range_unique(const _Key& __k) const;
 
     template <class _Key>
-        pair<iterator, iterator>
+    _LIBCPP_HIDE_FROM_ABI pair<iterator, iterator>
         __equal_range_multi(const _Key& __k);
     template <class _Key>
-        pair<const_iterator, const_iterator>
+    _LIBCPP_HIDE_FROM_ABI pair<const_iterator, const_iterator>
         __equal_range_multi(const _Key& __k) const;
 
-    void swap(__hash_table& __u)
+    _LIBCPP_HIDE_FROM_ABI void swap(__hash_table& __u)
 #if _LIBCPP_STD_VER <= 11
         _NOEXCEPT_(
             __is_nothrow_swappable<hasher>::value && __is_nothrow_swappable<key_equal>::value
@@ -1249,7 +1249,7 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     size_type max_bucket_count() const _NOEXCEPT
         {return max_size(); }
-    size_type bucket_size(size_type __n) const;
+    _LIBCPP_HIDE_FROM_ABI size_type bucket_size(size_type __n) const;
     _LIBCPP_INLINE_VISIBILITY float load_factor() const _NOEXCEPT
     {
         size_type __bc = bucket_count();
@@ -1300,34 +1300,36 @@ public:
 
 #ifdef _LIBCPP_ENABLE_DEBUG_MODE
 
-    bool __dereferenceable(const const_iterator* __i) const;
-    bool __decrementable(const const_iterator* __i) const;
-    bool __addable(const const_iterator* __i, ptrdiff_t __n) const;
-    bool __subscriptable(const const_iterator* __i, ptrdiff_t __n) const;
+    _LIBCPP_HIDE_FROM_ABI bool __dereferenceable(const const_iterator* __i) const;
+    _LIBCPP_HIDE_FROM_ABI bool __decrementable(const const_iterator* __i) const;
+    _LIBCPP_HIDE_FROM_ABI bool __addable(const const_iterator* __i, ptrdiff_t __n) const;
+    _LIBCPP_HIDE_FROM_ABI bool __subscriptable(const const_iterator* __i, ptrdiff_t __n) const;
 
 #endif // _LIBCPP_ENABLE_DEBUG_MODE
 
 private:
-    template <bool _UniqueKeys> void __rehash(size_type __n);
-    template <bool _UniqueKeys> void __do_rehash(size_type __n);
+    template <bool _UniqueKeys>
+    _LIBCPP_HIDE_FROM_ABI void __rehash(size_type __n);
+    template <bool _UniqueKeys>
+    _LIBCPP_HIDE_FROM_ABI void __do_rehash(size_type __n);
 
     template <class ..._Args>
-    __node_holder __construct_node(_Args&& ...__args);
+    _LIBCPP_HIDE_FROM_ABI __node_holder __construct_node(_Args&& ...__args);
 
     template <class _First, class ..._Rest>
-    __node_holder __construct_node_hash(size_t __hash, _First&& __f, _Rest&&... __rest);
+    _LIBCPP_HIDE_FROM_ABI __node_holder __construct_node_hash(size_t __hash, _First&& __f, _Rest&&... __rest);
 
 
     _LIBCPP_INLINE_VISIBILITY
     void __copy_assign_alloc(const __hash_table& __u)
         {__copy_assign_alloc(__u, integral_constant<bool,
              __node_traits::propagate_on_container_copy_assignment::value>());}
-    void __copy_assign_alloc(const __hash_table& __u, true_type);
+    _LIBCPP_HIDE_FROM_ABI void __copy_assign_alloc(const __hash_table& __u, true_type);
     _LIBCPP_INLINE_VISIBILITY
         void __copy_assign_alloc(const __hash_table&, false_type) {}
 
-    void __move_assign(__hash_table& __u, false_type);
-    void __move_assign(__hash_table& __u, true_type)
+    _LIBCPP_HIDE_FROM_ABI void __move_assign(__hash_table& __u, false_type);
+    _LIBCPP_HIDE_FROM_ABI void __move_assign(__hash_table& __u, true_type)
         _NOEXCEPT_(
             is_nothrow_move_assignable<__node_allocator>::value &&
             is_nothrow_move_assignable<hasher>::value &&
@@ -1353,8 +1355,8 @@ private:
     _LIBCPP_INLINE_VISIBILITY
         void __move_assign_alloc(__hash_table&, false_type) _NOEXCEPT {}
 
-    void __deallocate_node(__next_pointer __np) _NOEXCEPT;
-    __next_pointer __detach() _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI void __deallocate_node(__next_pointer __np) _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI __next_pointer __detach() _NOEXCEPT;
 
     template <class, class, class, class, class> friend class _LIBCPP_TEMPLATE_VIS unordered_map;
     template <class, class, class, class, class> friend class _LIBCPP_TEMPLATE_VIS unordered_multimap;
index aab04ce..e1d114a 100644 (file)
@@ -47,14 +47,14 @@ template<input_or_output_iterator _Iter, sentinel_for<_Iter> _Sent>
   requires (!same_as<_Iter, _Sent> && copyable<_Iter>)
 class common_iterator {
   struct __proxy {
-    constexpr const iter_value_t<_Iter>* operator->() const noexcept {
+    _LIBCPP_HIDE_FROM_ABI constexpr const iter_value_t<_Iter>* operator->() const noexcept {
       return _VSTD::addressof(__value_);
     }
     iter_value_t<_Iter> __value_;
   };
 
   struct __postfix_proxy {
-    constexpr const iter_value_t<_Iter>& operator*() const noexcept {
+    _LIBCPP_HIDE_FROM_ABI constexpr const iter_value_t<_Iter>& operator*() const noexcept {
       return __value_;
     }
     iter_value_t<_Iter> __value_;
@@ -63,14 +63,14 @@ class common_iterator {
 public:
   variant<_Iter, _Sent> __hold_;
 
-  common_iterator() requires default_initializable<_Iter> = default;
+  _LIBCPP_HIDE_FROM_ABI common_iterator() requires default_initializable<_Iter> = default;
 
-  constexpr common_iterator(_Iter __i) : __hold_(in_place_type<_Iter>, _VSTD::move(__i)) {}
-  constexpr common_iterator(_Sent __s) : __hold_(in_place_type<_Sent>, _VSTD::move(__s)) {}
+  _LIBCPP_HIDE_FROM_ABI constexpr common_iterator(_Iter __i) : __hold_(in_place_type<_Iter>, _VSTD::move(__i)) {}
+  _LIBCPP_HIDE_FROM_ABI constexpr common_iterator(_Sent __s) : __hold_(in_place_type<_Sent>, _VSTD::move(__s)) {}
 
   template<class _I2, class _S2>
     requires convertible_to<const _I2&, _Iter> && convertible_to<const _S2&, _Sent>
-  constexpr common_iterator(const common_iterator<_I2, _S2>& __other)
+  _LIBCPP_HIDE_FROM_ABI constexpr common_iterator(const common_iterator<_I2, _S2>& __other)
     : __hold_([&]() -> variant<_Iter, _Sent> {
       _LIBCPP_ASSERT(!__other.__hold_.valueless_by_exception(), "Attempted to construct from a valueless common_iterator");
       if (__other.__hold_.index() == 0)
@@ -81,7 +81,7 @@ public:
   template<class _I2, class _S2>
     requires convertible_to<const _I2&, _Iter> && convertible_to<const _S2&, _Sent> &&
              assignable_from<_Iter&, const _I2&> && assignable_from<_Sent&, const _S2&>
-  common_iterator& operator=(const common_iterator<_I2, _S2>& __other) {
+  _LIBCPP_HIDE_FROM_ABI common_iterator& operator=(const common_iterator<_I2, _S2>& __other) {
     _LIBCPP_ASSERT(!__other.__hold_.valueless_by_exception(), "Attempted to assign from a valueless common_iterator");
 
     auto __idx = __hold_.index();
@@ -102,13 +102,13 @@ public:
     return *this;
   }
 
-  constexpr decltype(auto) operator*()
+  _LIBCPP_HIDE_FROM_ABI constexpr decltype(auto) operator*()
   {
     _LIBCPP_ASSERT(std::holds_alternative<_Iter>(__hold_), "Attempted to dereference a non-dereferenceable common_iterator");
     return *_VSTD::__unchecked_get<_Iter>(__hold_);
   }
 
-  constexpr decltype(auto) operator*() const
+  _LIBCPP_HIDE_FROM_ABI constexpr decltype(auto) operator*() const
     requires __dereferenceable<const _Iter>
   {
     _LIBCPP_ASSERT(std::holds_alternative<_Iter>(__hold_), "Attempted to dereference a non-dereferenceable common_iterator");
@@ -116,7 +116,7 @@ public:
   }
 
   template<class _I2 = _Iter>
-  decltype(auto) operator->() const
+  _LIBCPP_HIDE_FROM_ABI decltype(auto) operator->() const
     requires indirectly_readable<const _I2> &&
     (requires(const _I2& __i) { __i.operator->(); } ||
      is_reference_v<iter_reference_t<_I2>> ||
@@ -133,12 +133,12 @@ public:
     }
   }
 
-  common_iterator& operator++() {
+  _LIBCPP_HIDE_FROM_ABI common_iterator& operator++() {
     _LIBCPP_ASSERT(std::holds_alternative<_Iter>(__hold_), "Attempted to increment a non-dereferenceable common_iterator");
     ++_VSTD::__unchecked_get<_Iter>(__hold_); return *this;
   }
 
-  decltype(auto) operator++(int) {
+  _LIBCPP_HIDE_FROM_ABI decltype(auto) operator++(int) {
     _LIBCPP_ASSERT(std::holds_alternative<_Iter>(__hold_), "Attempted to increment a non-dereferenceable common_iterator");
     if constexpr (forward_iterator<_Iter>) {
       auto __tmp = *this;
index 5f16474..2fd0af8 100644 (file)
@@ -44,7 +44,7 @@ public:
   move_sentinel& operator=(const move_sentinel<_S2>& __s)
     { __last_ = __s.base(); return *this; }
 
-  constexpr _Sent base() const { return __last_; }
+  _LIBCPP_HIDE_FROM_ABI constexpr _Sent base() const { return __last_; }
 
 private:
     _Sent __last_ = _Sent();
index b461831..b322c6b 100644 (file)
@@ -163,7 +163,7 @@ public:
     // locale operations:
     string name() const;
     bool operator==(const locale&) const;
-    bool operator!=(const locale& __y) const {return !(*this == __y);}
+    _LIBCPP_HIDE_FROM_ABI bool operator!=(const locale& __y) const {return !(*this == __y);}
     template <class _CharT, class _Traits, class _Allocator>
       _LIBCPP_METHOD_TEMPLATE_IMPLICIT_INSTANTIATION_VIS
       bool operator()(const basic_string<_CharT, _Traits, _Allocator>&,
index 244013c..6e7800c 100644 (file)
@@ -99,8 +99,7 @@ public:
     typedef true_type   propagate_on_container_move_assignment;
     typedef true_type   is_always_equal;
 
-    _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_SINCE_CXX20
-    allocator() _NOEXCEPT = default;
+    _LIBCPP_CONSTEXPR_SINCE_CXX20 allocator() _NOEXCEPT = default;
 
     template <class _Up>
     _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_SINCE_CXX20
@@ -188,8 +187,7 @@ public:
     typedef true_type   propagate_on_container_move_assignment;
     typedef true_type   is_always_equal;
 
-    _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_SINCE_CXX20
-    allocator() _NOEXCEPT = default;
+    _LIBCPP_CONSTEXPR_SINCE_CXX20 allocator() _NOEXCEPT = default;
 
     template <class _Up>
     _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_SINCE_CXX20
index cd1a866..ab449ad 100644 (file)
@@ -28,10 +28,10 @@ struct __builtin_new_allocator {
   struct __builtin_new_deleter {
     typedef void* pointer_type;
 
-    _LIBCPP_CONSTEXPR explicit __builtin_new_deleter(size_t __size, size_t __align)
+    _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR explicit __builtin_new_deleter(size_t __size, size_t __align)
         : __size_(__size), __align_(__align) {}
 
-    void operator()(void* __p) const _NOEXCEPT {
+    _LIBCPP_HIDE_FROM_ABI void operator()(void* __p) const _NOEXCEPT {
         _VSTD::__libcpp_deallocate(__p, __size_, __align_);
     }
 
@@ -42,25 +42,25 @@ struct __builtin_new_allocator {
 
   typedef unique_ptr<void, __builtin_new_deleter> __holder_t;
 
-  static __holder_t __allocate_bytes(size_t __s, size_t __align) {
+  _LIBCPP_HIDE_FROM_ABI static __holder_t __allocate_bytes(size_t __s, size_t __align) {
       return __holder_t(_VSTD::__libcpp_allocate(__s, __align),
                      __builtin_new_deleter(__s, __align));
   }
 
-  static void __deallocate_bytes(void* __p, size_t __s,
+  _LIBCPP_HIDE_FROM_ABI static void __deallocate_bytes(void* __p, size_t __s,
                                  size_t __align) _NOEXCEPT {
       _VSTD::__libcpp_deallocate(__p, __s, __align);
   }
 
   template <class _Tp>
   _LIBCPP_NODEBUG _LIBCPP_ALWAYS_INLINE
-  static __holder_t __allocate_type(size_t __n) {
+  _LIBCPP_HIDE_FROM_ABI static __holder_t __allocate_type(size_t __n) {
       return __allocate_bytes(__n * sizeof(_Tp), _LIBCPP_ALIGNOF(_Tp));
   }
 
   template <class _Tp>
   _LIBCPP_NODEBUG _LIBCPP_ALWAYS_INLINE
-  static void __deallocate_type(void* __p, size_t __n) _NOEXCEPT {
+  _LIBCPP_HIDE_FROM_ABI static void __deallocate_type(void* __p, size_t __n) _NOEXCEPT {
       __deallocate_bytes(__p, __n * sizeof(_Tp), _LIBCPP_ALIGNOF(_Tp));
   }
 };
index bea5385..01c3e01 100644 (file)
@@ -45,7 +45,7 @@ struct __fn {
   template <__nothrow_forward_iterator _ForwardIterator,
             __nothrow_sentinel_for<_ForwardIterator> _Sentinel>
     requires default_initializable<iter_value_t<_ForwardIterator>>
-  _ForwardIterator operator()(_ForwardIterator __first, _Sentinel __last) const {
+  _LIBCPP_HIDE_FROM_ABI _ForwardIterator operator()(_ForwardIterator __first, _Sentinel __last) const {
     using _ValueType = remove_reference_t<iter_reference_t<_ForwardIterator>>;
     return _VSTD::__uninitialized_default_construct<_ValueType>(
         _VSTD::move(__first), _VSTD::move(__last));
@@ -53,7 +53,7 @@ struct __fn {
 
   template <__nothrow_forward_range _ForwardRange>
     requires default_initializable<range_value_t<_ForwardRange>>
-  borrowed_iterator_t<_ForwardRange> operator()(_ForwardRange&& __range) const {
+  _LIBCPP_HIDE_FROM_ABI borrowed_iterator_t<_ForwardRange> operator()(_ForwardRange&& __range) const {
     return (*this)(ranges::begin(__range), ranges::end(__range));
   }
 };
@@ -71,7 +71,7 @@ namespace __uninitialized_default_construct_n {
 struct __fn {
   template <__nothrow_forward_iterator _ForwardIterator>
     requires default_initializable<iter_value_t<_ForwardIterator>>
-  _ForwardIterator operator()(_ForwardIterator __first,
+  _LIBCPP_HIDE_FROM_ABI _ForwardIterator operator()(_ForwardIterator __first,
                               iter_difference_t<_ForwardIterator> __n) const {
     using _ValueType = remove_reference_t<iter_reference_t<_ForwardIterator>>;
     return _VSTD::__uninitialized_default_construct_n<_ValueType>(_VSTD::move(__first), __n);
@@ -92,7 +92,7 @@ struct __fn {
   template <__nothrow_forward_iterator _ForwardIterator,
             __nothrow_sentinel_for<_ForwardIterator> _Sentinel>
     requires default_initializable<iter_value_t<_ForwardIterator>>
-  _ForwardIterator operator()(_ForwardIterator __first, _Sentinel __last) const {
+  _LIBCPP_HIDE_FROM_ABI _ForwardIterator operator()(_ForwardIterator __first, _Sentinel __last) const {
     using _ValueType = remove_reference_t<iter_reference_t<_ForwardIterator>>;
     return _VSTD::__uninitialized_value_construct<_ValueType>(
         _VSTD::move(__first), _VSTD::move(__last));
@@ -100,7 +100,7 @@ struct __fn {
 
   template <__nothrow_forward_range _ForwardRange>
     requires default_initializable<range_value_t<_ForwardRange>>
-  borrowed_iterator_t<_ForwardRange> operator()(_ForwardRange&& __range) const {
+  _LIBCPP_HIDE_FROM_ABI borrowed_iterator_t<_ForwardRange> operator()(_ForwardRange&& __range) const {
     return (*this)(ranges::begin(__range), ranges::end(__range));
   }
 };
@@ -118,7 +118,7 @@ namespace __uninitialized_value_construct_n {
 struct __fn {
   template <__nothrow_forward_iterator _ForwardIterator>
     requires default_initializable<iter_value_t<_ForwardIterator>>
-  _ForwardIterator operator()(_ForwardIterator __first,
+  _LIBCPP_HIDE_FROM_ABI _ForwardIterator operator()(_ForwardIterator __first,
                               iter_difference_t<_ForwardIterator> __n) const {
     using _ValueType = remove_reference_t<iter_reference_t<_ForwardIterator>>;
     return _VSTD::__uninitialized_value_construct_n<_ValueType>(_VSTD::move(__first), __n);
@@ -140,14 +140,14 @@ struct __fn {
             __nothrow_sentinel_for<_ForwardIterator> _Sentinel,
             class _Tp>
     requires constructible_from<iter_value_t<_ForwardIterator>, const _Tp&>
-  _ForwardIterator operator()(_ForwardIterator __first, _Sentinel __last, const _Tp& __x) const {
+  _LIBCPP_HIDE_FROM_ABI _ForwardIterator operator()(_ForwardIterator __first, _Sentinel __last, const _Tp& __x) const {
     using _ValueType = remove_reference_t<iter_reference_t<_ForwardIterator>>;
     return _VSTD::__uninitialized_fill<_ValueType>(_VSTD::move(__first), _VSTD::move(__last), __x);
   }
 
   template <__nothrow_forward_range _ForwardRange, class _Tp>
     requires constructible_from<range_value_t<_ForwardRange>, const _Tp&>
-  borrowed_iterator_t<_ForwardRange> operator()(_ForwardRange&& __range, const _Tp& __x) const {
+  _LIBCPP_HIDE_FROM_ABI borrowed_iterator_t<_ForwardRange> operator()(_ForwardRange&& __range, const _Tp& __x) const {
     return (*this)(ranges::begin(__range), ranges::end(__range), __x);
   }
 };
@@ -165,7 +165,7 @@ namespace __uninitialized_fill_n {
 struct __fn {
   template <__nothrow_forward_iterator _ForwardIterator, class _Tp>
     requires constructible_from<iter_value_t<_ForwardIterator>, const _Tp&>
-  _ForwardIterator operator()(_ForwardIterator __first,
+  _LIBCPP_HIDE_FROM_ABI _ForwardIterator operator()(_ForwardIterator __first,
                               iter_difference_t<_ForwardIterator> __n,
                               const _Tp& __x) const {
     using _ValueType = remove_reference_t<iter_reference_t<_ForwardIterator>>;
@@ -192,7 +192,7 @@ struct __fn {
             __nothrow_forward_iterator _OutputIterator,
             __nothrow_sentinel_for<_OutputIterator> _Sentinel2>
     requires constructible_from<iter_value_t<_OutputIterator>, iter_reference_t<_InputIterator>>
-  uninitialized_copy_result<_InputIterator, _OutputIterator>
+  _LIBCPP_HIDE_FROM_ABI uninitialized_copy_result<_InputIterator, _OutputIterator>
   operator()(_InputIterator __ifirst, _Sentinel1 __ilast, _OutputIterator __ofirst, _Sentinel2 __olast) const {
     using _ValueType = remove_reference_t<iter_reference_t<_OutputIterator>>;
 
@@ -203,7 +203,7 @@ struct __fn {
 
   template <input_range _InputRange, __nothrow_forward_range _OutputRange>
     requires constructible_from<range_value_t<_OutputRange>, range_reference_t<_InputRange>>
-  uninitialized_copy_result<borrowed_iterator_t<_InputRange>, borrowed_iterator_t<_OutputRange>>
+  _LIBCPP_HIDE_FROM_ABI uninitialized_copy_result<borrowed_iterator_t<_InputRange>, borrowed_iterator_t<_OutputRange>>
   operator()( _InputRange&& __in_range, _OutputRange&& __out_range) const {
     return (*this)(ranges::begin(__in_range), ranges::end(__in_range),
                    ranges::begin(__out_range), ranges::end(__out_range));
@@ -228,7 +228,7 @@ struct __fn {
            __nothrow_forward_iterator _OutputIterator,
            __nothrow_sentinel_for<_OutputIterator> _Sentinel>
     requires constructible_from<iter_value_t<_OutputIterator>, iter_reference_t<_InputIterator>>
-  uninitialized_copy_n_result<_InputIterator, _OutputIterator>
+  _LIBCPP_HIDE_FROM_ABI uninitialized_copy_n_result<_InputIterator, _OutputIterator>
   operator()(_InputIterator __ifirst, iter_difference_t<_InputIterator> __n,
              _OutputIterator __ofirst, _Sentinel __olast) const {
     using _ValueType = remove_reference_t<iter_reference_t<_OutputIterator>>;
@@ -257,7 +257,7 @@ struct __fn {
             __nothrow_forward_iterator _OutputIterator,
             __nothrow_sentinel_for<_OutputIterator> _Sentinel2>
     requires constructible_from<iter_value_t<_OutputIterator>, iter_rvalue_reference_t<_InputIterator>>
-  uninitialized_move_result<_InputIterator, _OutputIterator>
+  _LIBCPP_HIDE_FROM_ABI uninitialized_move_result<_InputIterator, _OutputIterator>
   operator()(_InputIterator __ifirst, _Sentinel1 __ilast, _OutputIterator __ofirst, _Sentinel2 __olast) const {
     using _ValueType = remove_reference_t<iter_reference_t<_OutputIterator>>;
     auto __iter_move = [](auto&& __iter) -> decltype(auto) { return ranges::iter_move(__iter); };
@@ -268,7 +268,7 @@ struct __fn {
 
   template <input_range _InputRange, __nothrow_forward_range _OutputRange>
     requires constructible_from<range_value_t<_OutputRange>, range_rvalue_reference_t<_InputRange>>
-  uninitialized_move_result<borrowed_iterator_t<_InputRange>, borrowed_iterator_t<_OutputRange>>
+  _LIBCPP_HIDE_FROM_ABI uninitialized_move_result<borrowed_iterator_t<_InputRange>, borrowed_iterator_t<_OutputRange>>
   operator()(_InputRange&& __in_range, _OutputRange&& __out_range) const {
     return (*this)(ranges::begin(__in_range), ranges::end(__in_range),
                    ranges::begin(__out_range), ranges::end(__out_range));
@@ -293,7 +293,7 @@ struct __fn {
            __nothrow_forward_iterator _OutputIterator,
            __nothrow_sentinel_for<_OutputIterator> _Sentinel>
     requires constructible_from<iter_value_t<_OutputIterator>, iter_rvalue_reference_t<_InputIterator>>
-  uninitialized_move_n_result<_InputIterator, _OutputIterator>
+  _LIBCPP_HIDE_FROM_ABI uninitialized_move_n_result<_InputIterator, _OutputIterator>
   operator()(_InputIterator __ifirst, iter_difference_t<_InputIterator> __n,
              _OutputIterator __ofirst, _Sentinel __olast) const {
     using _ValueType = remove_reference_t<iter_reference_t<_OutputIterator>>;
index 1d72eb6..db8b671 100644 (file)
@@ -124,8 +124,8 @@ class _LIBCPP_EXCEPTION_ABI bad_weak_ptr
     : public std::exception
 {
 public:
-    bad_weak_ptr() _NOEXCEPT = default;
-    bad_weak_ptr(const bad_weak_ptr&) _NOEXCEPT = default;
+    _LIBCPP_HIDE_FROM_ABI bad_weak_ptr() _NOEXCEPT = default;
+    _LIBCPP_HIDE_FROM_ABI bad_weak_ptr(const bad_weak_ptr&) _NOEXCEPT = default;
     ~bad_weak_ptr() _NOEXCEPT override;
     const char* what() const  _NOEXCEPT override;
 };
@@ -235,12 +235,12 @@ public:
         :  __data_(__compressed_pair<_Tp, _Dp>(__p, _VSTD::move(__d)), _VSTD::move(__a)) {}
 
 #ifndef _LIBCPP_HAS_NO_RTTI
-    const void* __get_deleter(const type_info&) const _NOEXCEPT override;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL const void* __get_deleter(const type_info&) const _NOEXCEPT override;
 #endif
 
 private:
-    void __on_zero_shared() _NOEXCEPT override;
-    void __on_zero_shared_weak() _NOEXCEPT override;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL void __on_zero_shared() _NOEXCEPT override;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL void __on_zero_shared_weak() _NOEXCEPT override;
 };
 
 #ifndef _LIBCPP_HAS_NO_RTTI
@@ -310,7 +310,7 @@ struct __shared_ptr_emplace
     _Tp* __get_elem() _NOEXCEPT { return __storage_.__get_elem(); }
 
 private:
-    void __on_zero_shared() _NOEXCEPT override {
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL void __on_zero_shared() _NOEXCEPT override {
 #if _LIBCPP_STD_VER >= 20
         if constexpr (is_same_v<typename _Alloc::value_type, __for_overwrite_tag>) {
             __get_elem()->~_Tp();
@@ -324,7 +324,7 @@ private:
 #endif
     }
 
-    void __on_zero_shared_weak() _NOEXCEPT override {
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL void __on_zero_shared_weak() _NOEXCEPT override {
         using _ControlBlockAlloc = typename __allocator_traits_rebind<_Alloc, __shared_ptr_emplace>::type;
         using _ControlBlockPointer = typename allocator_traits<_ControlBlockAlloc>::pointer;
         _ControlBlockAlloc __tmp(*__get_alloc());
@@ -351,13 +351,13 @@ private:
         _LIBCPP_HIDE_FROM_ABI ~_Storage() {
             __get_alloc()->~_Alloc();
         }
-        _Alloc* __get_alloc() _NOEXCEPT {
+        _LIBCPP_HIDE_FROM_ABI _Alloc* __get_alloc() _NOEXCEPT {
             _CompressedPair *__as_pair = reinterpret_cast<_CompressedPair*>(__blob_);
             typename _CompressedPair::_Base1* __first = _CompressedPair::__get_first_base(__as_pair);
             _Alloc *__alloc = reinterpret_cast<_Alloc*>(__first);
             return __alloc;
         }
-        _LIBCPP_NO_CFI _Tp* __get_elem() _NOEXCEPT {
+        _LIBCPP_HIDE_FROM_ABI _LIBCPP_NO_CFI _Tp* __get_elem() _NOEXCEPT {
             _CompressedPair *__as_pair = reinterpret_cast<_CompressedPair*>(__blob_);
             typename _CompressedPair::_Base2* __second = _CompressedPair::__get_second_base(__as_pair);
             _Tp *__elem = reinterpret_cast<_Tp*>(__second);
@@ -509,7 +509,7 @@ public:
 #endif
         >::value
     > >
-    explicit shared_ptr(_Yp* __p) : __ptr_(__p) {
+    _LIBCPP_HIDE_FROM_ABI explicit shared_ptr(_Yp* __p) : __ptr_(__p) {
         unique_ptr<_Yp> __hold(__p);
         typedef typename __shared_ptr_default_allocator<_Yp>::type _AllocT;
         typedef __shared_ptr_pointer<_Yp*, __shared_ptr_default_delete<_Tp, _Yp>, _AllocT> _CntrlBlk;
@@ -1099,7 +1099,7 @@ struct __unbounded_array_control_block<_Tp[], _Alloc> : __shared_weak_count
     ~__unbounded_array_control_block() override { } // can't be `= default` because of the sometimes-non-trivial union member __data_
 
 private:
-    void __on_zero_shared() _NOEXCEPT override {
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL void __on_zero_shared() _NOEXCEPT override {
 #if _LIBCPP_STD_VER >= 20
         if constexpr (is_same_v<typename _Alloc::value_type, __for_overwrite_tag>) {
             std::__reverse_destroy(__data_, __data_ + __count_);
@@ -1113,7 +1113,7 @@ private:
 #endif
     }
 
-    void __on_zero_shared_weak() _NOEXCEPT override {
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL void __on_zero_shared_weak() _NOEXCEPT override {
         using _AlignedStorage = __sp_aligned_storage<alignof(__unbounded_array_control_block)>;
         using _StorageAlloc = __allocator_traits_rebind_t<_Alloc, _AlignedStorage>;
         using _PointerTraits = pointer_traits<typename allocator_traits<_StorageAlloc>::pointer>;
@@ -1185,7 +1185,7 @@ struct __bounded_array_control_block<_Tp[_Count], _Alloc>
     ~__bounded_array_control_block() override { } // can't be `= default` because of the sometimes-non-trivial union member __data_
 
 private:
-    void __on_zero_shared() _NOEXCEPT override {
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL void __on_zero_shared() _NOEXCEPT override {
 #if _LIBCPP_STD_VER >= 20
         if constexpr (is_same_v<typename _Alloc::value_type, __for_overwrite_tag>) {
             std::__reverse_destroy(__data_, __data_ + _Count);
@@ -1199,7 +1199,7 @@ private:
 #endif
     }
 
-    void __on_zero_shared_weak() _NOEXCEPT override {
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL void __on_zero_shared_weak() _NOEXCEPT override {
         using _ControlBlockAlloc = __allocator_traits_rebind_t<_Alloc, __bounded_array_control_block>;
         using _PointerTraits = pointer_traits<typename allocator_traits<_ControlBlockAlloc>::pointer>;
 
@@ -1589,7 +1589,7 @@ public:
     template<class _Yp> _LIBCPP_INLINE_VISIBILITY weak_ptr(weak_ptr<_Yp>&& __r,
                    typename enable_if<__compatible_with<_Yp, _Tp>::value, __nat*>::type = 0)
                          _NOEXCEPT;
-    ~weak_ptr();
+    _LIBCPP_HIDE_FROM_ABI ~weak_ptr();
 
     _LIBCPP_INLINE_VISIBILITY
     weak_ptr& operator=(weak_ptr const& __r) _NOEXCEPT;
@@ -1633,7 +1633,7 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     bool expired() const _NOEXCEPT
         {return __cntrl_ == nullptr || __cntrl_->use_count() == 0;}
-    shared_ptr<_Tp> lock() const _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI shared_ptr<_Tp> lock() const _NOEXCEPT;
     template<class _Up>
         _LIBCPP_INLINE_VISIBILITY
         bool owner_before(const shared_ptr<_Up>& __r) const _NOEXCEPT
index 164688b..3ce8b4b 100644 (file)
@@ -32,7 +32,7 @@ struct __temp_value {
 #endif
     _Alloc &__a;
 
-    _LIBCPP_CONSTEXPR_SINCE_CXX20 _Tp *__addr() {
+    _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX20 _Tp *__addr() {
 #ifdef _LIBCPP_CXX03_LANG
         return reinterpret_cast<_Tp*>(std::addressof(__v));
 #else
@@ -40,15 +40,15 @@ struct __temp_value {
 #endif
     }
 
-    _LIBCPP_CONSTEXPR_SINCE_CXX20 _Tp &   get() { return *__addr(); }
+    _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX20 _Tp & get() { return *__addr(); }
 
     template<class... _Args>
-    _LIBCPP_NO_CFI
+    _LIBCPP_HIDE_FROM_ABI _LIBCPP_NO_CFI
     _LIBCPP_CONSTEXPR_SINCE_CXX20 __temp_value(_Alloc &__alloc, _Args&& ... __args) : __a(__alloc) {
       _Traits::construct(__a, __addr(), std::forward<_Args>(__args)...);
     }
 
-    _LIBCPP_CONSTEXPR_SINCE_CXX20 ~__temp_value() { _Traits::destroy(__a, __addr()); }
+    _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX20 ~__temp_value() { _Traits::destroy(__a, __addr()); }
 };
 
 _LIBCPP_END_NAMESPACE_STD
index 9878471..f60d23e 100644 (file)
@@ -35,7 +35,9 @@ class _LIBCPP_TYPE_VIS monotonic_buffer_resource : public memory_resource {
     char* __start_;
     char* __cur_;
     size_t __align_;
-    size_t __allocation_size() { return (reinterpret_cast<char*>(this) - __start_) + sizeof(*this); }
+    _LIBCPP_HIDE_FROM_ABI size_t __allocation_size() {
+      return (reinterpret_cast<char*>(this) - __start_) + sizeof(*this);
+    }
     void* __try_allocate_from_chunk(size_t, size_t);
   };
 
index c52adc4..f36e2c5 100644 (file)
@@ -50,7 +50,7 @@ public:
 
   _LIBCPP_HIDE_FROM_ABI polymorphic_allocator(memory_resource* __r) noexcept : __res_(__r) {}
 
-  polymorphic_allocator(const polymorphic_allocator&) = default;
+  _LIBCPP_HIDE_FROM_ABI polymorphic_allocator(const polymorphic_allocator&) = default;
 
   template <class _Tp>
   _LIBCPP_HIDE_FROM_ABI polymorphic_allocator(const polymorphic_allocator<_Tp>& __other) noexcept
@@ -74,29 +74,29 @@ public:
 
 #  if _LIBCPP_STD_VER >= 20
 
-  [[nodiscard]] [[using __gnu__: __alloc_size__(2), __alloc_align__(3)]] void*
+  [[nodiscard]] [[using __gnu__: __alloc_size__(2), __alloc_align__(3)]] _LIBCPP_HIDE_FROM_ABI void*
   allocate_bytes(size_t __nbytes, size_t __alignment = alignof(max_align_t)) {
     return __res_->allocate(__nbytes, __alignment);
   }
 
-  void deallocate_bytes(void* __ptr, size_t __nbytes, size_t __alignment = alignof(max_align_t)) {
+  _LIBCPP_HIDE_FROM_ABI void deallocate_bytes(void* __ptr, size_t __nbytes, size_t __alignment = alignof(max_align_t)) {
     __res_->deallocate(__ptr, __nbytes, __alignment);
   }
 
   template <class _Type>
-  [[nodiscard]] _Type* allocate_object(size_t __n = 1) {
+  [[nodiscard]] _LIBCPP_HIDE_FROM_ABI _Type* allocate_object(size_t __n = 1) {
     if (numeric_limits<size_t>::max() / sizeof(_Type) < __n)
       std::__throw_bad_array_new_length();
     return static_cast<_Type*>(allocate_bytes(__n * sizeof(_Type), alignof(_Type)));
   }
 
   template <class _Type>
-  void deallocate_object(_Type* __ptr, size_t __n = 1) {
+  _LIBCPP_HIDE_FROM_ABI void deallocate_object(_Type* __ptr, size_t __n = 1) {
     deallocate_bytes(__ptr, __n * sizeof(_Type), alignof(_Type));
   }
 
   template <class _Type, class... _CtorArgs>
-  [[nodiscard]] _Type* new_object(_CtorArgs&&... __ctor_args) {
+  [[nodiscard]] _LIBCPP_HIDE_FROM_ABI _Type* new_object(_CtorArgs&&... __ctor_args) {
     _Type* __ptr = allocate_object<_Type>();
     auto __guard = std::__make_exception_guard([&] { deallocate_object(__ptr); });
     construct(__ptr, std::forward<_CtorArgs>(__ctor_args)...);
@@ -105,7 +105,7 @@ public:
   }
 
   template <class _Type>
-  void delete_object(_Type* __ptr) {
+  _LIBCPP_HIDE_FROM_ABI void delete_object(_Type* __ptr) {
     destroy(__ptr);
     deallocate_object(__ptr);
   }
index b86ba06..576a29a 100644 (file)
@@ -46,7 +46,7 @@ public:
 
   synchronized_pool_resource(const synchronized_pool_resource&) = delete;
 
-  ~synchronized_pool_resource() override = default;
+  _LIBCPP_HIDE_FROM_ABI_VIRTUAL ~synchronized_pool_resource() override = default;
 
   synchronized_pool_resource& operator=(const synchronized_pool_resource&) = delete;
 
index 13def1e..819d4f3 100644 (file)
@@ -31,7 +31,7 @@ public:
   mutex& operator=(const mutex&) = delete;
 
 #  if defined(_LIBCPP_HAS_TRIVIAL_MUTEX_DESTRUCTION)
-  ~mutex() = default;
+  _LIBCPP_HIDE_FROM_ABI ~mutex() = default;
 #  else
   ~mutex() _NOEXCEPT;
 #  endif
index 7b0f055..18053c7 100644 (file)
@@ -42,7 +42,7 @@ public:
     public:
         typedef binomial_distribution distribution_type;
 
-        explicit param_type(result_type __t = 1, double __p = 0.5);
+        _LIBCPP_HIDE_FROM_ABI explicit param_type(result_type __t = 1, double __p = 0.5);
 
         _LIBCPP_INLINE_VISIBILITY
         result_type t() const {return __t_;}
@@ -85,7 +85,8 @@ public:
         _LIBCPP_INLINE_VISIBILITY
         result_type operator()(_URNG& __g)
         {return (*this)(__g, __p_);}
-    template<class _URNG> result_type operator()(_URNG& __g, const param_type& __p);
+    template<class _URNG>
+    _LIBCPP_HIDE_FROM_ABI result_type operator()(_URNG& __g, const param_type& __p);
 
     // property functions
     _LIBCPP_INLINE_VISIBILITY
index 077f158..7bdcb65 100644 (file)
@@ -92,7 +92,7 @@ public:
         seed(_Sseq& __q) {__e_.seed(__q); __n_ = 0;}
 
     // generating functions
-    result_type operator()();
+    _LIBCPP_HIDE_FROM_ABI result_type operator()();
     _LIBCPP_INLINE_VISIBILITY
     void discard(unsigned long long __z) {for (; __z; --__z) operator()();}
 
index 03f49ba..a6546fa 100644 (file)
@@ -53,10 +53,10 @@ public:
             : __p_(__wl.begin(), __wl.end()) {__init();}
 #endif // _LIBCPP_CXX03_LANG
         template<class _UnaryOperation>
-            param_type(size_t __nw, double __xmin, double __xmax,
+        _LIBCPP_HIDE_FROM_ABI param_type(size_t __nw, double __xmin, double __xmax,
                        _UnaryOperation __fw);
 
-        vector<double> probabilities() const;
+        _LIBCPP_HIDE_FROM_ABI vector<double> probabilities() const;
 
         friend _LIBCPP_INLINE_VISIBILITY
             bool operator==(const param_type& __x, const param_type& __y)
@@ -66,7 +66,7 @@ public:
             {return !(__x == __y);}
 
     private:
-        void __init();
+        _LIBCPP_HIDE_FROM_ABI void __init();
 
         friend class discrete_distribution;
 
@@ -115,7 +115,8 @@ public:
         _LIBCPP_INLINE_VISIBILITY
         result_type operator()(_URNG& __g)
         {return (*this)(__g, __p_);}
-    template<class _URNG> result_type operator()(_URNG& __g, const param_type& __p);
+    template<class _URNG>
+    _LIBCPP_HIDE_FROM_ABI result_type operator()(_URNG& __g, const param_type& __p);
 
     // property functions
     _LIBCPP_INLINE_VISIBILITY
index 8edf1ac..b33b072 100644 (file)
@@ -79,7 +79,8 @@ public:
         _LIBCPP_INLINE_VISIBILITY
         result_type operator()(_URNG& __g)
         {return (*this)(__g, __p_);}
-    template<class _URNG> result_type operator()(_URNG& __g, const param_type& __p);
+    template<class _URNG>
+    _LIBCPP_HIDE_FROM_ABI result_type operator()(_URNG& __g, const param_type& __p);
 
     // property functions
     _LIBCPP_INLINE_VISIBILITY
index b3cba39..c583ec0 100644 (file)
@@ -84,7 +84,8 @@ public:
         _LIBCPP_INLINE_VISIBILITY
         result_type operator()(_URNG& __g)
         {return (*this)(__g, __p_);}
-    template<class _URNG> result_type operator()(_URNG& __g, const param_type& __p);
+    template<class _URNG>
+    _LIBCPP_HIDE_FROM_ABI result_type operator()(_URNG& __g, const param_type& __p);
 
     // property functions
     _LIBCPP_INLINE_VISIBILITY
index b5479ac..b757607 100644 (file)
@@ -82,7 +82,8 @@ public:
         _LIBCPP_INLINE_VISIBILITY
         result_type operator()(_URNG& __g)
         {return (*this)(__g, __p_);}
-    template<class _URNG> result_type operator()(_URNG& __g, const param_type& __p);
+    template<class _URNG>
+    _LIBCPP_HIDE_FROM_ABI result_type operator()(_URNG& __g, const param_type& __p);
 
     // property functions
     _LIBCPP_INLINE_VISIBILITY
index 0d7fc3f..777f6b5 100644 (file)
@@ -85,7 +85,8 @@ public:
         _LIBCPP_INLINE_VISIBILITY
         result_type operator()(_URNG& __g)
         {return (*this)(__g, __p_);}
-    template<class _URNG> result_type operator()(_URNG& __g, const param_type& __p);
+    template<class _URNG>
+    _LIBCPP_HIDE_FROM_ABI result_type operator()(_URNG& __g, const param_type& __p);
 
     // property functions
     _LIBCPP_INLINE_VISIBILITY
index 2cd4096..a86c221 100644 (file)
@@ -164,7 +164,7 @@ public:
 private:
     _LIBCPP_INLINE_VISIBILITY
     result_type __eval(false_type);
-    result_type __eval(true_type);
+    _LIBCPP_HIDE_FROM_ABI result_type __eval(true_type);
 
     template <size_t __count>
         _LIBCPP_INLINE_VISIBILITY
index aa24a06..2c2276e 100644 (file)
@@ -296,9 +296,9 @@ private:
     void seed(false_type, false_type, result_type __s) {__x_ = __s % __m;}
 
     template<class _Sseq>
-        void __seed(_Sseq& __q, integral_constant<unsigned, 1>);
+    _LIBCPP_HIDE_FROM_ABI void __seed(_Sseq& __q, integral_constant<unsigned, 1>);
     template<class _Sseq>
-        void __seed(_Sseq& __q, integral_constant<unsigned, 2>);
+    _LIBCPP_HIDE_FROM_ABI void __seed(_Sseq& __q, integral_constant<unsigned, 2>);
 
     template <class _CharT, class _Traits,
               class _Up, _Up _Ap, _Up _Cp, _Up _Np>
index 89df825..663a6c7 100644 (file)
@@ -140,7 +140,7 @@ public:
         explicit mersenne_twister_engine(_Sseq& __q,
         typename enable_if<__is_seed_sequence<_Sseq, mersenne_twister_engine>::value>::type* = 0)
         {seed(__q);}
-    void seed(result_type __sd = default_seed);
+    _LIBCPP_HIDE_FROM_ABI void seed(result_type __sd = default_seed);
     template<class _Sseq>
         _LIBCPP_INLINE_VISIBILITY
         typename enable_if
@@ -152,7 +152,7 @@ public:
             {__seed(__q, integral_constant<unsigned, 1 + (__w - 1) / 32>());}
 
     // generating functions
-    result_type operator()();
+    _LIBCPP_HIDE_FROM_ABI result_type operator()();
     _LIBCPP_INLINE_VISIBILITY
     void discard(unsigned long long __z) {for (; __z; --__z) operator()();}
 
@@ -198,9 +198,9 @@ public:
 private:
 
     template<class _Sseq>
-        void __seed(_Sseq& __q, integral_constant<unsigned, 1>);
+    _LIBCPP_HIDE_FROM_ABI void __seed(_Sseq& __q, integral_constant<unsigned, 1>);
     template<class _Sseq>
-        void __seed(_Sseq& __q, integral_constant<unsigned, 2>);
+    _LIBCPP_HIDE_FROM_ABI void __seed(_Sseq& __q, integral_constant<unsigned, 2>);
 
     template <size_t __count>
         _LIBCPP_INLINE_VISIBILITY
index 333c935..450ff09 100644 (file)
@@ -85,7 +85,8 @@ public:
         _LIBCPP_INLINE_VISIBILITY
         result_type operator()(_URNG& __g)
         {return (*this)(__g, __p_);}
-    template<class _URNG> result_type operator()(_URNG& __g, const param_type& __p);
+    template<class _URNG>
+    _LIBCPP_HIDE_FROM_ABI result_type operator()(_URNG& __g, const param_type& __p);
 
     // property functions
     _LIBCPP_INLINE_VISIBILITY
index 93f3d1f..e2bf041 100644 (file)
@@ -86,7 +86,8 @@ public:
         _LIBCPP_INLINE_VISIBILITY
         result_type operator()(_URNG& __g)
         {return (*this)(__g, __p_);}
-    template<class _URNG> result_type operator()(_URNG& __g, const param_type& __p);
+    template<class _URNG>
+    _LIBCPP_HIDE_FROM_ABI result_type operator()(_URNG& __g, const param_type& __p);
 
     // property functions
     _LIBCPP_INLINE_VISIBILITY
index a1f3ef9..5b26ab6 100644 (file)
@@ -41,19 +41,19 @@ public:
     public:
         typedef piecewise_constant_distribution distribution_type;
 
-        param_type();
+        _LIBCPP_HIDE_FROM_ABI param_type();
         template<class _InputIteratorB, class _InputIteratorW>
-            param_type(_InputIteratorB __f_b, _InputIteratorB __l_b,
+        _LIBCPP_HIDE_FROM_ABI param_type(_InputIteratorB __f_b, _InputIteratorB __l_b,
                        _InputIteratorW __f_w);
 #ifndef _LIBCPP_CXX03_LANG
         template<class _UnaryOperation>
-            param_type(initializer_list<result_type> __bl, _UnaryOperation __fw);
+        _LIBCPP_HIDE_FROM_ABI param_type(initializer_list<result_type> __bl, _UnaryOperation __fw);
 #endif // _LIBCPP_CXX03_LANG
         template<class _UnaryOperation>
-            param_type(size_t __nw, result_type __xmin, result_type __xmax,
+        _LIBCPP_HIDE_FROM_ABI param_type(size_t __nw, result_type __xmin, result_type __xmax,
                        _UnaryOperation __fw);
-        param_type(param_type const&) = default;
-        param_type & operator=(const param_type& __rhs);
+        _LIBCPP_HIDE_FROM_ABI param_type(param_type const&) = default;
+        _LIBCPP_HIDE_FROM_ABI param_type & operator=(const param_type& __rhs);
 
         _LIBCPP_INLINE_VISIBILITY
         vector<result_type> intervals() const {return __b_;}
@@ -68,7 +68,7 @@ public:
             {return !(__x == __y);}
 
     private:
-        void __init();
+        _LIBCPP_HIDE_FROM_ABI void __init();
 
         friend class piecewise_constant_distribution;
 
@@ -125,7 +125,8 @@ public:
         _LIBCPP_INLINE_VISIBILITY
         result_type operator()(_URNG& __g)
         {return (*this)(__g, __p_);}
-    template<class _URNG> result_type operator()(_URNG& __g, const param_type& __p);
+    template<class _URNG>
+    _LIBCPP_HIDE_FROM_ABI result_type operator()(_URNG& __g, const param_type& __p);
 
     // property functions
     _LIBCPP_INLINE_VISIBILITY
index 0430b24..6be44b2 100644 (file)
@@ -41,19 +41,19 @@ public:
     public:
         typedef piecewise_linear_distribution distribution_type;
 
-        param_type();
+        _LIBCPP_HIDE_FROM_ABI param_type();
         template<class _InputIteratorB, class _InputIteratorW>
-            param_type(_InputIteratorB __f_b, _InputIteratorB __l_b,
+        _LIBCPP_HIDE_FROM_ABI param_type(_InputIteratorB __f_b, _InputIteratorB __l_b,
                        _InputIteratorW __f_w);
 #ifndef _LIBCPP_CXX03_LANG
         template<class _UnaryOperation>
-            param_type(initializer_list<result_type> __bl, _UnaryOperation __fw);
+        _LIBCPP_HIDE_FROM_ABI param_type(initializer_list<result_type> __bl, _UnaryOperation __fw);
 #endif // _LIBCPP_CXX03_LANG
         template<class _UnaryOperation>
-            param_type(size_t __nw, result_type __xmin, result_type __xmax,
+        _LIBCPP_HIDE_FROM_ABI param_type(size_t __nw, result_type __xmin, result_type __xmax,
                        _UnaryOperation __fw);
-        param_type(param_type const&) = default;
-        param_type & operator=(const param_type& __rhs);
+        _LIBCPP_HIDE_FROM_ABI param_type(param_type const&) = default;
+        _LIBCPP_HIDE_FROM_ABI param_type & operator=(const param_type& __rhs);
 
         _LIBCPP_INLINE_VISIBILITY
         vector<result_type> intervals() const {return __b_;}
@@ -68,7 +68,7 @@ public:
             {return !(__x == __y);}
 
     private:
-        void __init();
+        _LIBCPP_HIDE_FROM_ABI void __init();
 
         friend class piecewise_linear_distribution;
 
@@ -125,7 +125,8 @@ public:
         _LIBCPP_INLINE_VISIBILITY
         result_type operator()(_URNG& __g)
         {return (*this)(__g, __p_);}
-    template<class _URNG> result_type operator()(_URNG& __g, const param_type& __p);
+    template<class _URNG>
+    _LIBCPP_HIDE_FROM_ABI result_type operator()(_URNG& __g, const param_type& __p);
 
     // property functions
     _LIBCPP_INLINE_VISIBILITY
index 2b39937..eed120e 100644 (file)
@@ -52,7 +52,7 @@ public:
     public:
         typedef poisson_distribution distribution_type;
 
-        explicit param_type(double __mean = 1.0);
+        _LIBCPP_HIDE_FROM_ABI explicit param_type(double __mean = 1.0);
 
         _LIBCPP_INLINE_VISIBILITY
         double mean() const {return __mean_;}
@@ -93,7 +93,8 @@ public:
         _LIBCPP_INLINE_VISIBILITY
         result_type operator()(_URNG& __g)
         {return (*this)(__g, __p_);}
-    template<class _URNG> result_type operator()(_URNG& __g, const param_type& __p);
+    template<class _URNG>
+    _LIBCPP_HIDE_FROM_ABI result_type operator()(_URNG& __g, const param_type& __p);
 
     // property functions
     _LIBCPP_INLINE_VISIBILITY
index e82b437..e16afea 100644 (file)
@@ -58,7 +58,7 @@ public:
 
     // constructors
 #ifndef _LIBCPP_CXX03_LANG
-    random_device() : random_device("/dev/urandom") {}
+    _LIBCPP_HIDE_FROM_ABI random_device() : random_device("/dev/urandom") {}
     explicit random_device(const string& __token);
 #else
     explicit random_device(const string& __token = "/dev/urandom");
index 5c40d15..e9a0596 100644 (file)
@@ -53,7 +53,7 @@ public:
 
     // generating functions
     template<class _RandomAccessIterator>
-        void generate(_RandomAccessIterator __first, _RandomAccessIterator __last);
+    _LIBCPP_HIDE_FROM_ABI void generate(_RandomAccessIterator __first, _RandomAccessIterator __last);
 
     // property functions
     _LIBCPP_INLINE_VISIBILITY
@@ -71,7 +71,7 @@ public:
 
 private:
     template<class _InputIterator>
-    void __init(_InputIterator __first, _InputIterator __last);
+    _LIBCPP_HIDE_FROM_ABI void __init(_InputIterator __first, _InputIterator __last);
 
     vector<result_type> __v_;
 };
index 64847aa..2d2be23 100644 (file)
@@ -81,7 +81,8 @@ public:
         _LIBCPP_INLINE_VISIBILITY
         result_type operator()(_URNG& __g)
         {return (*this)(__g, __p_);}
-    template<class _URNG> result_type operator()(_URNG& __g, const param_type& __p);
+    template<class _URNG>
+    _LIBCPP_HIDE_FROM_ABI result_type operator()(_URNG& __g, const param_type& __p);
 
     // property functions
     _LIBCPP_INLINE_VISIBILITY
index 9294cc2..c8954ca 100644 (file)
@@ -120,7 +120,7 @@ public:
             {__seed(__q, integral_constant<unsigned, 1 + (__w - 1) / 32>());}
 
     // generating functions
-    result_type operator()();
+    _LIBCPP_HIDE_FROM_ABI result_type operator()();
     _LIBCPP_INLINE_VISIBILITY
     void discard(unsigned long long __z) {for (; __z; --__z) operator()();}
 
@@ -154,12 +154,12 @@ public:
 
 private:
 
-    void seed(result_type __sd, integral_constant<unsigned, 1>);
-    void seed(result_type __sd, integral_constant<unsigned, 2>);
+    _LIBCPP_HIDE_FROM_ABI void seed(result_type __sd, integral_constant<unsigned, 1>);
+    _LIBCPP_HIDE_FROM_ABI void seed(result_type __sd, integral_constant<unsigned, 2>);
     template<class _Sseq>
-        void __seed(_Sseq& __q, integral_constant<unsigned, 1>);
+    _LIBCPP_HIDE_FROM_ABI void __seed(_Sseq& __q, integral_constant<unsigned, 1>);
     template<class _Sseq>
-        void __seed(_Sseq& __q, integral_constant<unsigned, 2>);
+    _LIBCPP_HIDE_FROM_ABI void __seed(_Sseq& __q, integral_constant<unsigned, 2>);
 };
 
 template<class _UIntType, size_t __w, size_t __s, size_t __r>
index 5415876..3a2b95c 100644 (file)
@@ -64,14 +64,14 @@ private:
 
 public:
     // constructors and seeding functions
-    __independent_bits_engine(_Engine& __e, size_t __w);
+    _LIBCPP_HIDE_FROM_ABI __independent_bits_engine(_Engine& __e, size_t __w);
 
     // generating functions
-    result_type operator()() {return __eval(integral_constant<bool, _Rp != 0>());}
+    _LIBCPP_HIDE_FROM_ABI result_type operator()() {return __eval(integral_constant<bool, _Rp != 0>());}
 
 private:
-    result_type __eval(false_type);
-    result_type __eval(true_type);
+    _LIBCPP_HIDE_FROM_ABI result_type __eval(false_type);
+    _LIBCPP_HIDE_FROM_ABI result_type __eval(true_type);
 };
 
 template<class _Engine, class _UIntType>
@@ -167,12 +167,12 @@ public:
     public:
         typedef uniform_int_distribution distribution_type;
 
-        explicit param_type(result_type __a = 0,
+        _LIBCPP_HIDE_FROM_ABI explicit param_type(result_type __a = 0,
                             result_type __b = numeric_limits<result_type>::max())
             : __a_(__a), __b_(__b) {}
 
-        result_type a() const {return __a_;}
-        result_type b() const {return __b_;}
+        _LIBCPP_HIDE_FROM_ABI result_type a() const {return __a_;}
+        _LIBCPP_HIDE_FROM_ABI result_type b() const {return __b_;}
 
         _LIBCPP_HIDE_FROM_ABI
         friend bool operator==(const param_type& __x, const param_type& __y)
@@ -188,8 +188,8 @@ private:
 public:
     // constructors and reset functions
 #ifndef _LIBCPP_CXX03_LANG
-    uniform_int_distribution() : uniform_int_distribution(0) {}
-    explicit uniform_int_distribution(
+    _LIBCPP_HIDE_FROM_ABI uniform_int_distribution() : uniform_int_distribution(0) {}
+    _LIBCPP_HIDE_FROM_ABI explicit uniform_int_distribution(
         result_type __a, result_type __b = numeric_limits<result_type>::max())
         : __p_(param_type(__a, __b)) {}
 #else
@@ -198,23 +198,25 @@ public:
         result_type __b = numeric_limits<result_type>::max())
         : __p_(param_type(__a, __b)) {}
 #endif
-    explicit uniform_int_distribution(const param_type& __p) : __p_(__p) {}
-    void reset() {}
+    _LIBCPP_HIDE_FROM_ABI explicit uniform_int_distribution(const param_type& __p) : __p_(__p) {}
+    _LIBCPP_HIDE_FROM_ABI void reset() {}
 
     // generating functions
-    template<class _URNG> result_type operator()(_URNG& __g)
+    template<class _URNG>
+    _LIBCPP_HIDE_FROM_ABI result_type operator()(_URNG& __g)
         {return (*this)(__g, __p_);}
-    template<class _URNG> result_type operator()(_URNG& __g, const param_type& __p);
+    template<class _URNG>
+    _LIBCPP_HIDE_FROM_ABI result_type operator()(_URNG& __g, const param_type& __p);
 
     // property functions
-    result_type a() const {return __p_.a();}
-    result_type b() const {return __p_.b();}
+    _LIBCPP_HIDE_FROM_ABI result_type a() const {return __p_.a();}
+    _LIBCPP_HIDE_FROM_ABI result_type b() const {return __p_.b();}
 
-    param_type param() const {return __p_;}
-    void param(const param_type& __p) {__p_ = __p;}
+    _LIBCPP_HIDE_FROM_ABI param_type param() const {return __p_;}
+    _LIBCPP_HIDE_FROM_ABI void param(const param_type& __p) {__p_ = __p;}
 
-    result_type min() const {return a();}
-    result_type max() const {return b();}
+    _LIBCPP_HIDE_FROM_ABI result_type min() const {return a();}
+    _LIBCPP_HIDE_FROM_ABI result_type max() const {return b();}
 
     _LIBCPP_HIDE_FROM_ABI
     friend bool operator==(const uniform_int_distribution& __x,
index dd6d6b3..1388cef 100644 (file)
@@ -64,7 +64,7 @@ public:
 #ifndef _LIBCPP_CXX03_LANG
     _LIBCPP_INLINE_VISIBILITY
     uniform_real_distribution() : uniform_real_distribution(0) {}
-    explicit uniform_real_distribution(result_type __a, result_type __b = 1)
+    _LIBCPP_HIDE_FROM_ABI explicit uniform_real_distribution(result_type __a, result_type __b = 1)
         : __p_(param_type(__a, __b)) {}
 #else
     _LIBCPP_INLINE_VISIBILITY
index 87668c3..0df8ab4 100644 (file)
@@ -71,7 +71,7 @@ namespace ranges {
     _View __base_ = _View();
 
 public:
-    drop_view() requires default_initializable<_View> = default;
+    _LIBCPP_HIDE_FROM_ABI drop_view() requires default_initializable<_View> = default;
 
     _LIBCPP_HIDE_FROM_ABI
     constexpr _LIBCPP_EXPLICIT_SINCE_CXX23 drop_view(_View __base, range_difference_t<_View> __count)
index 5713942..52e8e82 100644 (file)
@@ -281,7 +281,8 @@ namespace ranges {
     public:
       _LIBCPP_HIDE_FROM_ABI
       __sentinel() = default;
-      constexpr explicit __sentinel(_BoundSentinel __bound_sentinel) : __bound_sentinel_(std::move(__bound_sentinel)) {}
+      _LIBCPP_HIDE_FROM_ABI constexpr explicit __sentinel(_BoundSentinel __bound_sentinel)
+          : __bound_sentinel_(std::move(__bound_sentinel)) {}
 
       _LIBCPP_HIDE_FROM_ABI
       friend constexpr bool operator==(const __iterator& __x, const __sentinel& __y) {
index 2e6e72f..f522396 100644 (file)
@@ -43,10 +43,11 @@ namespace ranges {
     // This helper class is needed to perform copy and move elision when
     // constructing the contained type from an iterator.
     struct __wrapper {
-      template<class ..._Args>
-      constexpr explicit __wrapper(__forward_tag, _Args&& ...__args) : __t_(std::forward<_Args>(__args)...) { }
-      template<class _Fn>
-      constexpr explicit __wrapper(__from_tag, _Fn const& __f) : __t_(__f()) { }
+      template <class... _Args>
+      _LIBCPP_HIDE_FROM_ABI constexpr explicit __wrapper(__forward_tag, _Args&&... __args)
+          : __t_(std::forward<_Args>(__args)...) {}
+      template <class _Fn>
+      _LIBCPP_HIDE_FROM_ABI constexpr explicit __wrapper(__from_tag, _Fn const& __f) : __t_(__f()) {}
       _Tp __t_;
     };
 
index cb1d0d5..a5deed3 100644 (file)
@@ -38,11 +38,11 @@ namespace ranges {
     _Rp __r_ = _Rp();
 
 public:
-    owning_view() requires default_initializable<_Rp> = default;
+    _LIBCPP_HIDE_FROM_ABI owning_view() requires default_initializable<_Rp> = default;
     _LIBCPP_HIDE_FROM_ABI constexpr owning_view(_Rp&& __r) : __r_(std::move(__r)) {}
 
-    owning_view(owning_view&&) = default;
-    owning_view& operator=(owning_view&&) = default;
+    _LIBCPP_HIDE_FROM_ABI owning_view(owning_view&&) = default;
+    _LIBCPP_HIDE_FROM_ABI owning_view& operator=(owning_view&&) = default;
 
     _LIBCPP_HIDE_FROM_ABI constexpr _Rp& base() & noexcept { return __r_; }
     _LIBCPP_HIDE_FROM_ABI constexpr const _Rp& base() const& noexcept { return __r_; }
index f8fd2f6..532485b 100644 (file)
@@ -41,7 +41,7 @@ struct __range_adaptor_closure;
 // i.e. something that can be called via the `x | f` notation.
 template <class _Fn>
 struct __range_adaptor_closure_t : _Fn, __range_adaptor_closure<__range_adaptor_closure_t<_Fn>> {
-    constexpr explicit __range_adaptor_closure_t(_Fn&& __f) : _Fn(std::move(__f)) { }
+    _LIBCPP_HIDE_FROM_ABI constexpr explicit __range_adaptor_closure_t(_Fn&& __f) : _Fn(std::move(__f)) { }
 };
 _LIBCPP_CTAD_SUPPORTED_FOR_TYPE(__range_adaptor_closure_t);
 
index b41b5db..a51364d 100644 (file)
@@ -82,7 +82,7 @@ namespace ranges {
 
   private:
     static constexpr bool _MustProvideSizeAtConstruction = !_StoreSize; // just to improve compiler diagnostics
-    struct _Empty { constexpr _Empty(auto) noexcept { } };
+    struct _Empty { _LIBCPP_HIDE_FROM_ABI constexpr _Empty(auto) noexcept { } };
     using _Size = conditional_t<_StoreSize, make_unsigned_t<iter_difference_t<_Iter>>, _Empty>;
     _LIBCPP_NO_UNIQUE_ADDRESS _Iter __begin_ = _Iter();
     _LIBCPP_NO_UNIQUE_ADDRESS _Sent __end_ = _Sent();
index 9d96242..e7c63a2 100644 (file)
@@ -85,14 +85,14 @@ struct _LIBCPP_DEPRECATED_("char_traits<T> for T not equal to char, wchar_t, cha
     using pos_type   = streampos;
     using state_type = mbstate_t;
 
-    static inline void _LIBCPP_CONSTEXPR_SINCE_CXX17
+    static inline void _LIBCPP_CONSTEXPR_SINCE_CXX17 _LIBCPP_HIDE_FROM_ABI
         assign(char_type& __c1, const char_type& __c2) _NOEXCEPT {__c1 = __c2;}
-    static inline _LIBCPP_CONSTEXPR bool eq(char_type __c1, char_type __c2) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR bool eq(char_type __c1, char_type __c2) _NOEXCEPT
         {return __c1 == __c2;}
-    static inline _LIBCPP_CONSTEXPR bool lt(char_type __c1, char_type __c2) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR bool lt(char_type __c1, char_type __c2) _NOEXCEPT
         {return __c1 < __c2;}
 
-    static _LIBCPP_CONSTEXPR_SINCE_CXX17
+    static _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX17
     int compare(const char_type* __s1, const char_type* __s2, size_t __n) {
         for (; __n; --__n, ++__s1, ++__s2)
         {
@@ -120,7 +120,7 @@ struct _LIBCPP_DEPRECATED_("char_traits<T> for T not equal to char, wchar_t, cha
         }
         return nullptr;
     }
-    static _LIBCPP_CONSTEXPR_SINCE_CXX20
+    static _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX20
     char_type*       move(char_type* __s1, const char_type* __s2, size_t __n) {
         if (__n == 0) return __s1;
         char_type* __r = __s1;
@@ -158,15 +158,15 @@ struct _LIBCPP_DEPRECATED_("char_traits<T> for T not equal to char, wchar_t, cha
         return __r;
     }
 
-    static inline _LIBCPP_CONSTEXPR int_type  not_eof(int_type __c) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR int_type  not_eof(int_type __c) _NOEXCEPT
         {return eq_int_type(__c, eof()) ? ~eof() : __c;}
-    static inline _LIBCPP_CONSTEXPR char_type to_char_type(int_type __c) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR char_type to_char_type(int_type __c) _NOEXCEPT
         {return char_type(__c);}
-    static inline _LIBCPP_CONSTEXPR int_type  to_int_type(char_type __c) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR int_type  to_int_type(char_type __c) _NOEXCEPT
         {return int_type(__c);}
-    static inline _LIBCPP_CONSTEXPR bool      eq_int_type(int_type __c1, int_type __c2) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR bool      eq_int_type(int_type __c1, int_type __c2) _NOEXCEPT
         {return __c1 == __c2;}
-    static inline _LIBCPP_CONSTEXPR int_type  eof() _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR int_type  eof() _NOEXCEPT
         {return int_type(EOF);}
 };
 
@@ -203,36 +203,39 @@ struct _LIBCPP_TEMPLATE_VIS char_traits<char>
     using comparison_category = strong_ordering;
 #endif
 
-    static inline _LIBCPP_CONSTEXPR_SINCE_CXX17
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX17
     void assign(char_type& __c1, const char_type& __c2) _NOEXCEPT {__c1 = __c2;}
-    static inline _LIBCPP_CONSTEXPR bool eq(char_type __c1, char_type __c2) _NOEXCEPT
+
+    // TODO: Make this _LIBCPP_HIDE_FROM_ABI
+    static inline _LIBCPP_HIDDEN _LIBCPP_CONSTEXPR bool eq(char_type __c1, char_type __c2) _NOEXCEPT
             {return __c1 == __c2;}
-    static inline _LIBCPP_CONSTEXPR bool lt(char_type __c1, char_type __c2) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR bool lt(char_type __c1, char_type __c2) _NOEXCEPT
         {return (unsigned char)__c1 < (unsigned char)__c2;}
 
-  static _LIBCPP_CONSTEXPR_SINCE_CXX17 int compare(const char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT {
+  static _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX17 int
+  compare(const char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT {
     if (__n == 0)
       return 0;
     return std::__constexpr_memcmp(__s1, __s2, __n);
   }
 
-  static inline size_t _LIBCPP_CONSTEXPR_SINCE_CXX17 length(const char_type* __s)  _NOEXCEPT {
+  static inline _LIBCPP_HIDE_FROM_ABI size_t _LIBCPP_CONSTEXPR_SINCE_CXX17 length(const char_type* __s)  _NOEXCEPT {
     return std::__constexpr_strlen(__s);
   }
 
-  static _LIBCPP_CONSTEXPR_SINCE_CXX17
+  static _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX17
   const char_type* find(const char_type* __s, size_t __n, const char_type& __a) _NOEXCEPT {
     if (__n == 0)
         return nullptr;
     return std::__constexpr_char_memchr(__s, static_cast<int>(__a), __n);
   }
 
-    static inline _LIBCPP_CONSTEXPR_SINCE_CXX20
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX20
     char_type* move(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT {
         return std::__char_traits_move(__s1, __s2, __n);
     }
 
-    static inline _LIBCPP_CONSTEXPR_SINCE_CXX20
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX20
     char_type* copy(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT {
         if (!__libcpp_is_constant_evaluated())
             _LIBCPP_ASSERT(__s2 < __s1 || __s2 >= __s1+__n, "char_traits::copy overlapped range");
@@ -240,21 +243,21 @@ struct _LIBCPP_TEMPLATE_VIS char_traits<char>
         return __s1;
     }
 
-    static inline _LIBCPP_CONSTEXPR_SINCE_CXX20
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX20
     char_type* assign(char_type* __s, size_t __n, char_type __a) _NOEXCEPT {
         std::fill_n(__s, __n, __a);
         return __s;
     }
 
-    static inline _LIBCPP_CONSTEXPR int_type  not_eof(int_type __c) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR int_type  not_eof(int_type __c) _NOEXCEPT
         {return eq_int_type(__c, eof()) ? ~eof() : __c;}
-    static inline _LIBCPP_CONSTEXPR char_type to_char_type(int_type __c) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR char_type to_char_type(int_type __c) _NOEXCEPT
         {return char_type(__c);}
-    static inline _LIBCPP_CONSTEXPR int_type to_int_type(char_type __c) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR int_type to_int_type(char_type __c) _NOEXCEPT
         {return int_type((unsigned char)__c);}
-    static inline _LIBCPP_CONSTEXPR bool eq_int_type(int_type __c1, int_type __c2) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR bool eq_int_type(int_type __c1, int_type __c2) _NOEXCEPT
         {return __c1 == __c2;}
-    static inline _LIBCPP_CONSTEXPR int_type  eof() _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR int_type  eof() _NOEXCEPT
         {return int_type(EOF);}
 };
 
@@ -273,36 +276,37 @@ struct _LIBCPP_TEMPLATE_VIS char_traits<wchar_t>
     using comparison_category = strong_ordering;
 #endif
 
-    static inline _LIBCPP_CONSTEXPR_SINCE_CXX17
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX17
     void assign(char_type& __c1, const char_type& __c2) _NOEXCEPT {__c1 = __c2;}
-    static inline _LIBCPP_CONSTEXPR bool eq(char_type __c1, char_type __c2) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR bool eq(char_type __c1, char_type __c2) _NOEXCEPT
         {return __c1 == __c2;}
-    static inline _LIBCPP_CONSTEXPR bool lt(char_type __c1, char_type __c2) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR bool lt(char_type __c1, char_type __c2) _NOEXCEPT
         {return __c1 < __c2;}
 
-  static _LIBCPP_CONSTEXPR_SINCE_CXX17 int compare(const char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT {
+  static _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX17 int
+  compare(const char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT {
     if (__n == 0)
-        return 0;
+      return 0;
     return std::__constexpr_wmemcmp(__s1, __s2, __n);
   }
 
-  static _LIBCPP_CONSTEXPR_SINCE_CXX17 size_t length(const char_type* __s) _NOEXCEPT {
+  static _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX17 size_t length(const char_type* __s) _NOEXCEPT {
     return std::__constexpr_wcslen(__s);
   }
 
-  static _LIBCPP_CONSTEXPR_SINCE_CXX17
+  static _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX17
   const char_type* find(const char_type* __s, size_t __n, const char_type& __a) _NOEXCEPT {
     if (__n == 0)
         return nullptr;
     return std::__constexpr_wmemchr(__s, __a, __n);
   }
 
-    static inline _LIBCPP_CONSTEXPR_SINCE_CXX20
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX20
     char_type* move(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT {
         return std::__char_traits_move(__s1, __s2, __n);
     }
 
-    static inline _LIBCPP_CONSTEXPR_SINCE_CXX20
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX20
     char_type* copy(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT {
         if (!__libcpp_is_constant_evaluated())
             _LIBCPP_ASSERT(__s2 < __s1 || __s2 >= __s1+__n, "char_traits::copy overlapped range");
@@ -310,21 +314,21 @@ struct _LIBCPP_TEMPLATE_VIS char_traits<wchar_t>
         return __s1;
     }
 
-    static inline _LIBCPP_CONSTEXPR_SINCE_CXX20
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX20
     char_type* assign(char_type* __s, size_t __n, char_type __a) _NOEXCEPT {
         std::fill_n(__s, __n, __a);
         return __s;
     }
 
-    static inline _LIBCPP_CONSTEXPR int_type  not_eof(int_type __c) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR int_type  not_eof(int_type __c) _NOEXCEPT
         {return eq_int_type(__c, eof()) ? ~eof() : __c;}
-    static inline _LIBCPP_CONSTEXPR char_type to_char_type(int_type __c) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR char_type to_char_type(int_type __c) _NOEXCEPT
         {return char_type(__c);}
-    static inline _LIBCPP_CONSTEXPR int_type to_int_type(char_type __c) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR int_type to_int_type(char_type __c) _NOEXCEPT
         {return int_type(__c);}
-    static inline _LIBCPP_CONSTEXPR bool eq_int_type(int_type __c1, int_type __c2) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR bool eq_int_type(int_type __c1, int_type __c2) _NOEXCEPT
         {return __c1 == __c2;}
-    static inline _LIBCPP_CONSTEXPR int_type eof() _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR int_type eof() _NOEXCEPT
         {return int_type(WEOF);}
 };
 #endif // _LIBCPP_HAS_NO_WIDE_CHARACTERS
@@ -343,11 +347,11 @@ struct _LIBCPP_TEMPLATE_VIS char_traits<char8_t>
     using comparison_category = strong_ordering;
 #endif
 
-    static inline constexpr void assign(char_type& __c1, const char_type& __c2) noexcept
+    static inline _LIBCPP_HIDE_FROM_ABI constexpr void assign(char_type& __c1, const char_type& __c2) noexcept
         {__c1 = __c2;}
-    static inline constexpr bool eq(char_type __c1, char_type __c2) noexcept
+    static inline _LIBCPP_HIDE_FROM_ABI constexpr bool eq(char_type __c1, char_type __c2) noexcept
         {return __c1 == __c2;}
-    static inline constexpr bool lt(char_type __c1, char_type __c2) noexcept
+    static inline _LIBCPP_HIDE_FROM_ABI constexpr bool lt(char_type __c1, char_type __c2) noexcept
         {return __c1 < __c2;}
 
   static _LIBCPP_HIDE_FROM_ABI constexpr int
@@ -355,18 +359,18 @@ struct _LIBCPP_TEMPLATE_VIS char_traits<char8_t>
       return std::__constexpr_memcmp(__s1, __s2, __n);
   }
 
-    static constexpr
+    static _LIBCPP_HIDE_FROM_ABI constexpr
     size_t           length(const char_type* __s) _NOEXCEPT;
 
     _LIBCPP_INLINE_VISIBILITY static constexpr
     const char_type* find(const char_type* __s, size_t __n, const char_type& __a) _NOEXCEPT;
 
-    static _LIBCPP_CONSTEXPR_SINCE_CXX20
+    static _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX20
     char_type*       move(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT {
         return std::__char_traits_move(__s1, __s2, __n);
     }
 
-    static _LIBCPP_CONSTEXPR_SINCE_CXX20
+    static _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX20
     char_type*       copy(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT {
         if (!__libcpp_is_constant_evaluated())
             _LIBCPP_ASSERT(__s2 < __s1 || __s2 >= __s1+__n, "char_traits::copy overlapped range");
@@ -374,21 +378,21 @@ struct _LIBCPP_TEMPLATE_VIS char_traits<char8_t>
         return __s1;
     }
 
-    static _LIBCPP_CONSTEXPR_SINCE_CXX20
+    static _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX20
     char_type*       assign(char_type* __s, size_t __n, char_type __a) _NOEXCEPT {
         std::fill_n(__s, __n, __a);
         return __s;
     }
 
-    static inline constexpr int_type  not_eof(int_type __c) noexcept
+    static inline _LIBCPP_HIDE_FROM_ABI constexpr int_type  not_eof(int_type __c) noexcept
         {return eq_int_type(__c, eof()) ? ~eof() : __c;}
-    static inline constexpr char_type to_char_type(int_type __c) noexcept
+    static inline _LIBCPP_HIDE_FROM_ABI constexpr char_type to_char_type(int_type __c) noexcept
         {return char_type(__c);}
-    static inline constexpr int_type to_int_type(char_type __c) noexcept
+    static inline _LIBCPP_HIDE_FROM_ABI constexpr int_type to_int_type(char_type __c) noexcept
         {return int_type(__c);}
-    static inline constexpr bool eq_int_type(int_type __c1, int_type __c2) noexcept
+    static inline _LIBCPP_HIDE_FROM_ABI constexpr bool eq_int_type(int_type __c1, int_type __c2) noexcept
         {return __c1 == __c2;}
-    static inline constexpr int_type eof() noexcept
+    static inline _LIBCPP_HIDE_FROM_ABI constexpr int_type eof() noexcept
         {return int_type(EOF);}
 };
 
@@ -431,11 +435,11 @@ struct _LIBCPP_TEMPLATE_VIS char_traits<char16_t>
     using comparison_category = strong_ordering;
 #endif
 
-    static inline _LIBCPP_CONSTEXPR_SINCE_CXX17
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX17
     void assign(char_type& __c1, const char_type& __c2) _NOEXCEPT {__c1 = __c2;}
-    static inline _LIBCPP_CONSTEXPR bool eq(char_type __c1, char_type __c2) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR bool eq(char_type __c1, char_type __c2) _NOEXCEPT
         {return __c1 == __c2;}
-    static inline _LIBCPP_CONSTEXPR bool lt(char_type __c1, char_type __c2) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR bool lt(char_type __c1, char_type __c2) _NOEXCEPT
         {return __c1 < __c2;}
 
     _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR_SINCE_CXX17
@@ -464,15 +468,15 @@ struct _LIBCPP_TEMPLATE_VIS char_traits<char16_t>
         return __s;
     }
 
-    static inline _LIBCPP_CONSTEXPR int_type  not_eof(int_type __c) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR int_type  not_eof(int_type __c) _NOEXCEPT
         {return eq_int_type(__c, eof()) ? ~eof() : __c;}
-    static inline _LIBCPP_CONSTEXPR char_type to_char_type(int_type __c) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR char_type to_char_type(int_type __c) _NOEXCEPT
         {return char_type(__c);}
-    static inline _LIBCPP_CONSTEXPR int_type to_int_type(char_type __c) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR int_type to_int_type(char_type __c) _NOEXCEPT
         {return int_type(__c);}
-    static inline _LIBCPP_CONSTEXPR bool eq_int_type(int_type __c1, int_type __c2) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR bool eq_int_type(int_type __c1, int_type __c2) _NOEXCEPT
         {return __c1 == __c2;}
-    static inline _LIBCPP_CONSTEXPR int_type eof() _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR int_type eof() _NOEXCEPT
         {return int_type(0xFFFF);}
 };
 
@@ -525,11 +529,11 @@ struct _LIBCPP_TEMPLATE_VIS char_traits<char32_t>
     using comparison_category = strong_ordering;
 #endif
 
-    static inline _LIBCPP_CONSTEXPR_SINCE_CXX17
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX17
     void assign(char_type& __c1, const char_type& __c2) _NOEXCEPT {__c1 = __c2;}
-    static inline _LIBCPP_CONSTEXPR bool eq(char_type __c1, char_type __c2) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR bool eq(char_type __c1, char_type __c2) _NOEXCEPT
         {return __c1 == __c2;}
-    static inline _LIBCPP_CONSTEXPR bool lt(char_type __c1, char_type __c2) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR bool lt(char_type __c1, char_type __c2) _NOEXCEPT
         {return __c1 < __c2;}
 
     _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR_SINCE_CXX17
@@ -556,15 +560,15 @@ struct _LIBCPP_TEMPLATE_VIS char_traits<char32_t>
         return __s;
     }
 
-    static inline _LIBCPP_CONSTEXPR int_type  not_eof(int_type __c) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR int_type  not_eof(int_type __c) _NOEXCEPT
         {return eq_int_type(__c, eof()) ? ~eof() : __c;}
-    static inline _LIBCPP_CONSTEXPR char_type to_char_type(int_type __c) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR char_type to_char_type(int_type __c) _NOEXCEPT
         {return char_type(__c);}
-    static inline _LIBCPP_CONSTEXPR int_type to_int_type(char_type __c) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR int_type to_int_type(char_type __c) _NOEXCEPT
         {return int_type(__c);}
-    static inline _LIBCPP_CONSTEXPR bool eq_int_type(int_type __c1, int_type __c2) _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR bool eq_int_type(int_type __c1, int_type __c2) _NOEXCEPT
         {return __c1 == __c2;}
-    static inline _LIBCPP_CONSTEXPR int_type eof() _NOEXCEPT
+    static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR int_type eof() _NOEXCEPT
         {return int_type(0xFFFFFFFF);}
 };
 
index d199feb..13c5c24 100644 (file)
@@ -32,7 +32,7 @@ public:
   system_error(int __ev, const error_category& __ecat, const string& __what_arg);
   system_error(int __ev, const error_category& __ecat, const char* __what_arg);
   system_error(int __ev, const error_category& __ecat);
-  system_error(const system_error&) _NOEXCEPT = default;
+  _LIBCPP_HIDE_FROM_ABI system_error(const system_error&) _NOEXCEPT = default;
   ~system_error() _NOEXCEPT override;
 
   _LIBCPP_HIDE_FROM_ABI const error_code& code() const _NOEXCEPT { return __ec_; }
index 8b2965a..02577ca 100644 (file)
@@ -798,7 +798,7 @@ public:
     bool __value_constructed;
 
 
-    __tree_node_destructor(const __tree_node_destructor &) = default;
+    _LIBCPP_HIDE_FROM_ABI __tree_node_destructor(const __tree_node_destructor &) = default;
     __tree_node_destructor& operator=(const __tree_node_destructor&) = delete;
 
     _LIBCPP_INLINE_VISIBILITY
@@ -1101,36 +1101,36 @@ public:
     __node_pointer __root() const _NOEXCEPT
         {return static_cast<__node_pointer>(__end_node()->__left_);}
 
-    __node_base_pointer* __root_ptr() const _NOEXCEPT {
+    _LIBCPP_HIDE_FROM_ABI __node_base_pointer* __root_ptr() const _NOEXCEPT {
         return _VSTD::addressof(__end_node()->__left_);
     }
 
     typedef __tree_iterator<value_type, __node_pointer, difference_type>             iterator;
     typedef __tree_const_iterator<value_type, __node_pointer, difference_type> const_iterator;
 
-    explicit __tree(const value_compare& __comp)
+    _LIBCPP_HIDE_FROM_ABI explicit __tree(const value_compare& __comp)
         _NOEXCEPT_(
             is_nothrow_default_constructible<__node_allocator>::value &&
             is_nothrow_copy_constructible<value_compare>::value);
-    explicit __tree(const allocator_type& __a);
-    __tree(const value_compare& __comp, const allocator_type& __a);
-    __tree(const __tree& __t);
-    __tree& operator=(const __tree& __t);
+    _LIBCPP_HIDE_FROM_ABI explicit __tree(const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI __tree(const value_compare& __comp, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI __tree(const __tree& __t);
+    _LIBCPP_HIDE_FROM_ABI __tree& operator=(const __tree& __t);
     template <class _ForwardIterator>
-        void __assign_unique(_ForwardIterator __first, _ForwardIterator __last);
+    _LIBCPP_HIDE_FROM_ABI void __assign_unique(_ForwardIterator __first, _ForwardIterator __last);
     template <class _InputIterator>
-        void __assign_multi(_InputIterator __first, _InputIterator __last);
-    __tree(__tree&& __t)
+    _LIBCPP_HIDE_FROM_ABI void __assign_multi(_InputIterator __first, _InputIterator __last);
+    _LIBCPP_HIDE_FROM_ABI __tree(__tree&& __t)
         _NOEXCEPT_(
             is_nothrow_move_constructible<__node_allocator>::value &&
             is_nothrow_move_constructible<value_compare>::value);
-    __tree(__tree&& __t, const allocator_type& __a);
-    __tree& operator=(__tree&& __t)
+    _LIBCPP_HIDE_FROM_ABI __tree(__tree&& __t, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI __tree& operator=(__tree&& __t)
         _NOEXCEPT_(
             __node_traits::propagate_on_container_move_assignment::value &&
             is_nothrow_move_assignable<value_compare>::value &&
             is_nothrow_move_assignable<__node_allocator>::value);
-    ~__tree();
+    _LIBCPP_HIDE_FROM_ABI ~__tree();
 
     _LIBCPP_INLINE_VISIBILITY
           iterator begin()  _NOEXCEPT {return       iterator(__begin_node());}
@@ -1147,9 +1147,9 @@ public:
                 __node_traits::max_size(__node_alloc()),
                 numeric_limits<difference_type >::max());}
 
-    void clear() _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI void clear() _NOEXCEPT;
 
-    void swap(__tree& __t)
+    _LIBCPP_HIDE_FROM_ABI void swap(__tree& __t)
 #if _LIBCPP_STD_VER <= 11
         _NOEXCEPT_(
             __is_nothrow_swappable<value_compare>::value
@@ -1161,23 +1161,23 @@ public:
 #endif
 
     template <class _Key, class ..._Args>
-    pair<iterator, bool>
+    _LIBCPP_HIDE_FROM_ABI pair<iterator, bool>
     __emplace_unique_key_args(_Key const&, _Args&&... __args);
     template <class _Key, class ..._Args>
-    pair<iterator, bool>
+    _LIBCPP_HIDE_FROM_ABI pair<iterator, bool>
     __emplace_hint_unique_key_args(const_iterator, _Key const&, _Args&&...);
 
     template <class... _Args>
-    pair<iterator, bool> __emplace_unique_impl(_Args&&... __args);
+    _LIBCPP_HIDE_FROM_ABI pair<iterator, bool> __emplace_unique_impl(_Args&&... __args);
 
     template <class... _Args>
-    iterator __emplace_hint_unique_impl(const_iterator __p, _Args&&... __args);
+    _LIBCPP_HIDE_FROM_ABI iterator __emplace_hint_unique_impl(const_iterator __p, _Args&&... __args);
 
     template <class... _Args>
-    iterator __emplace_multi(_Args&&... __args);
+    _LIBCPP_HIDE_FROM_ABI iterator __emplace_multi(_Args&&... __args);
 
     template <class... _Args>
-    iterator __emplace_hint_multi(const_iterator __p, _Args&&... __args);
+    _LIBCPP_HIDE_FROM_ABI iterator __emplace_hint_multi(const_iterator __p, _Args&&... __args);
 
     template <class _Pp>
     _LIBCPP_INLINE_VISIBILITY
@@ -1362,33 +1362,33 @@ public:
     _NodeHandle __node_handle_extract(const_iterator);
 #endif
 
-    iterator erase(const_iterator __p);
-    iterator erase(const_iterator __f, const_iterator __l);
+    _LIBCPP_HIDE_FROM_ABI iterator erase(const_iterator __p);
+    _LIBCPP_HIDE_FROM_ABI iterator erase(const_iterator __f, const_iterator __l);
     template <class _Key>
-        size_type __erase_unique(const _Key& __k);
+    _LIBCPP_HIDE_FROM_ABI size_type __erase_unique(const _Key& __k);
     template <class _Key>
-        size_type __erase_multi(const _Key& __k);
+    _LIBCPP_HIDE_FROM_ABI size_type __erase_multi(const _Key& __k);
 
-    void __insert_node_at(__parent_pointer     __parent,
+    _LIBCPP_HIDE_FROM_ABI void __insert_node_at(__parent_pointer     __parent,
                           __node_base_pointer& __child,
                           __node_base_pointer __new_node) _NOEXCEPT;
 
     template <class _Key>
-        iterator find(const _Key& __v);
+    _LIBCPP_HIDE_FROM_ABI iterator find(const _Key& __v);
     template <class _Key>
-        const_iterator find(const _Key& __v) const;
+    _LIBCPP_HIDE_FROM_ABI const_iterator find(const _Key& __v) const;
 
     template <class _Key>
-        size_type __count_unique(const _Key& __k) const;
+    _LIBCPP_HIDE_FROM_ABI size_type __count_unique(const _Key& __k) const;
     template <class _Key>
-        size_type __count_multi(const _Key& __k) const;
+    _LIBCPP_HIDE_FROM_ABI size_type __count_multi(const _Key& __k) const;
 
     template <class _Key>
         _LIBCPP_INLINE_VISIBILITY
         iterator lower_bound(const _Key& __v)
             {return __lower_bound(__v, __root(), __end_node());}
     template <class _Key>
-        iterator __lower_bound(const _Key& __v,
+    _LIBCPP_HIDE_FROM_ABI iterator __lower_bound(const _Key& __v,
                                __node_pointer __root,
                                __iter_pointer __result);
     template <class _Key>
@@ -1396,7 +1396,7 @@ public:
         const_iterator lower_bound(const _Key& __v) const
             {return __lower_bound(__v, __root(), __end_node());}
     template <class _Key>
-        const_iterator __lower_bound(const _Key& __v,
+    _LIBCPP_HIDE_FROM_ABI const_iterator __lower_bound(const _Key& __v,
                                      __node_pointer __root,
                                      __iter_pointer __result) const;
     template <class _Key>
@@ -1404,7 +1404,7 @@ public:
         iterator upper_bound(const _Key& __v)
             {return __upper_bound(__v, __root(), __end_node());}
     template <class _Key>
-        iterator __upper_bound(const _Key& __v,
+    _LIBCPP_HIDE_FROM_ABI iterator __upper_bound(const _Key& __v,
                                __node_pointer __root,
                                __iter_pointer __result);
     template <class _Key>
@@ -1412,55 +1412,52 @@ public:
         const_iterator upper_bound(const _Key& __v) const
             {return __upper_bound(__v, __root(), __end_node());}
     template <class _Key>
-        const_iterator __upper_bound(const _Key& __v,
+    _LIBCPP_HIDE_FROM_ABI const_iterator __upper_bound(const _Key& __v,
                                      __node_pointer __root,
                                      __iter_pointer __result) const;
     template <class _Key>
-        pair<iterator, iterator>
+    _LIBCPP_HIDE_FROM_ABI pair<iterator, iterator>
         __equal_range_unique(const _Key& __k);
     template <class _Key>
-        pair<const_iterator, const_iterator>
+    _LIBCPP_HIDE_FROM_ABI pair<const_iterator, const_iterator>
         __equal_range_unique(const _Key& __k) const;
 
     template <class _Key>
-        pair<iterator, iterator>
+    _LIBCPP_HIDE_FROM_ABI pair<iterator, iterator>
         __equal_range_multi(const _Key& __k);
     template <class _Key>
-        pair<const_iterator, const_iterator>
+    _LIBCPP_HIDE_FROM_ABI pair<const_iterator, const_iterator>
         __equal_range_multi(const _Key& __k) const;
 
     typedef __tree_node_destructor<__node_allocator> _Dp;
     typedef unique_ptr<__node, _Dp> __node_holder;
 
-    __node_holder remove(const_iterator __p) _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI __node_holder remove(const_iterator __p) _NOEXCEPT;
 private:
-    __node_base_pointer&
-        __find_leaf_low(__parent_pointer& __parent, const key_type& __v);
-    __node_base_pointer&
-        __find_leaf_high(__parent_pointer& __parent, const key_type& __v);
-    __node_base_pointer&
-        __find_leaf(const_iterator __hint,
-                    __parent_pointer& __parent, const key_type& __v);
+    _LIBCPP_HIDE_FROM_ABI __node_base_pointer& __find_leaf_low(__parent_pointer& __parent, const key_type& __v);
+    _LIBCPP_HIDE_FROM_ABI __node_base_pointer& __find_leaf_high(__parent_pointer& __parent, const key_type& __v);
+    _LIBCPP_HIDE_FROM_ABI __node_base_pointer&
+    __find_leaf(const_iterator __hint, __parent_pointer& __parent, const key_type& __v);
     // FIXME: Make this function const qualified. Unfortunately doing so
     // breaks existing code which uses non-const callable comparators.
     template <class _Key>
-    __node_base_pointer&
-        __find_equal(__parent_pointer& __parent, const _Key& __v);
+    _LIBCPP_HIDE_FROM_ABI __node_base_pointer& __find_equal(__parent_pointer& __parent, const _Key& __v);
     template <class _Key>
     _LIBCPP_INLINE_VISIBILITY __node_base_pointer&
     __find_equal(__parent_pointer& __parent, const _Key& __v) const {
       return const_cast<__tree*>(this)->__find_equal(__parent, __v);
     }
     template <class _Key>
-    __node_base_pointer&
+    _LIBCPP_HIDE_FROM_ABI __node_base_pointer&
         __find_equal(const_iterator __hint, __parent_pointer& __parent,
                      __node_base_pointer& __dummy,
                      const _Key& __v);
 
     template <class ..._Args>
-    __node_holder __construct_node(_Args&& ...__args);
+    _LIBCPP_HIDE_FROM_ABI __node_holder __construct_node(_Args&& ...__args);
 
-    void destroy(__node_pointer __nd) _NOEXCEPT;
+    // TODO: Make this _LIBCPP_HIDE_FROM_ABI
+    _LIBCPP_HIDDEN void destroy(__node_pointer __nd) _NOEXCEPT;
 
     _LIBCPP_INLINE_VISIBILITY
     void __copy_assign_alloc(const __tree& __t)
@@ -1477,8 +1474,8 @@ private:
     _LIBCPP_INLINE_VISIBILITY
     void __copy_assign_alloc(const __tree&, false_type) {}
 
-    void __move_assign(__tree& __t, false_type);
-    void __move_assign(__tree& __t, true_type)
+    _LIBCPP_HIDE_FROM_ABI void __move_assign(__tree& __t, false_type);
+    _LIBCPP_HIDE_FROM_ABI void __move_assign(__tree& __t, true_type)
         _NOEXCEPT_(is_nothrow_move_assignable<value_compare>::value &&
                    is_nothrow_move_assignable<__node_allocator>::value);
 
index 589f450..f00fad5 100644 (file)
@@ -123,14 +123,14 @@ using __tuple_like_with_size _LIBCPP_NODEBUG = __tuple_like_with_size_imp<
 
 struct _LIBCPP_TYPE_VIS __check_tuple_constructor_fail {
 
-    static constexpr bool __enable_explicit_default() { return false; }
-    static constexpr bool __enable_implicit_default() { return false; }
+    static _LIBCPP_HIDE_FROM_ABI constexpr bool __enable_explicit_default() { return false; }
+    static _LIBCPP_HIDE_FROM_ABI constexpr bool __enable_implicit_default() { return false; }
     template <class ...>
-    static constexpr bool __enable_explicit() { return false; }
+    static _LIBCPP_HIDE_FROM_ABI constexpr bool __enable_explicit() { return false; }
     template <class ...>
-    static constexpr bool __enable_implicit() { return false; }
+    static _LIBCPP_HIDE_FROM_ABI constexpr bool __enable_implicit() { return false; }
     template <class ...>
-    static constexpr bool __enable_assign() { return false; }
+    static _LIBCPP_HIDE_FROM_ABI constexpr bool __enable_assign() { return false; }
 };
 #endif // !defined(_LIBCPP_CXX03_LANG)
 
index c1c6a67..d1a3575 100644 (file)
@@ -22,20 +22,20 @@ _LIBCPP_BEGIN_NAMESPACE_STD
 #if _LIBCPP_STD_VER >= 17
 
 struct _LIBCPP_TYPE_VIS in_place_t {
-    explicit in_place_t() = default;
+  explicit in_place_t() = default;
 };
 inline constexpr in_place_t in_place{};
 
 template <class _Tp>
 struct _LIBCPP_TEMPLATE_VIS in_place_type_t {
-    explicit in_place_type_t() = default;
+  _LIBCPP_HIDE_FROM_ABI explicit in_place_type_t() = default;
 };
 template <class _Tp>
 inline constexpr in_place_type_t<_Tp> in_place_type{};
 
 template <size_t _Idx>
 struct _LIBCPP_TEMPLATE_VIS in_place_index_t {
-    explicit in_place_index_t() = default;
+  explicit in_place_index_t() = default;
 };
 template <size_t _Idx>
 inline constexpr in_place_index_t<_Idx> in_place_index{};
index 77baba9..3f80368 100644 (file)
@@ -70,8 +70,8 @@ struct _LIBCPP_TEMPLATE_VIS pair
     _T1 first;
     _T2 second;
 
-    pair(pair const&) = default;
-    pair(pair&&) = default;
+    _LIBCPP_HIDE_FROM_ABI pair(pair const&) = default;
+    _LIBCPP_HIDE_FROM_ABI pair(pair&&) = default;
 
 #ifdef _LIBCPP_CXX03_LANG
     _LIBCPP_HIDE_FROM_ABI
@@ -93,37 +93,37 @@ struct _LIBCPP_TEMPLATE_VIS pair
 #else
     struct _CheckArgs {
       template <int&...>
-      static constexpr bool __enable_explicit_default() {
+      static _LIBCPP_HIDE_FROM_ABI constexpr bool __enable_explicit_default() {
           return is_default_constructible<_T1>::value
               && is_default_constructible<_T2>::value
               && !__enable_implicit_default<>();
       }
 
       template <int&...>
-      static constexpr bool __enable_implicit_default() {
+      static _LIBCPP_HIDE_FROM_ABI constexpr bool __enable_implicit_default() {
           return __is_implicitly_default_constructible<_T1>::value
               && __is_implicitly_default_constructible<_T2>::value;
       }
 
       template <class _U1, class _U2>
-      static constexpr bool __is_pair_constructible() {
+      static _LIBCPP_HIDE_FROM_ABI constexpr bool __is_pair_constructible() {
           return is_constructible<first_type, _U1>::value
               && is_constructible<second_type, _U2>::value;
       }
 
       template <class _U1, class _U2>
-      static constexpr bool __is_implicit() {
+      static _LIBCPP_HIDE_FROM_ABI constexpr bool __is_implicit() {
           return is_convertible<_U1, first_type>::value
               && is_convertible<_U2, second_type>::value;
       }
 
       template <class _U1, class _U2>
-      static constexpr bool __enable_explicit() {
+      static _LIBCPP_HIDE_FROM_ABI constexpr bool __enable_explicit() {
           return __is_pair_constructible<_U1, _U2>() && !__is_implicit<_U1, _U2>();
       }
 
       template <class _U1, class _U2>
-      static constexpr bool __enable_implicit() {
+      static _LIBCPP_HIDE_FROM_ABI constexpr bool __enable_implicit() {
           return __is_pair_constructible<_U1, _U2>() && __is_implicit<_U1, _U2>();
       }
     };
@@ -134,18 +134,18 @@ struct _LIBCPP_TEMPLATE_VIS pair
 
     struct _CheckTupleLikeConstructor {
         template <class _Tuple>
-        static constexpr bool __enable_implicit() {
+        static _LIBCPP_HIDE_FROM_ABI constexpr bool __enable_implicit() {
             return __tuple_convertible<_Tuple, pair>::value;
         }
 
         template <class _Tuple>
-        static constexpr bool __enable_explicit() {
+        static _LIBCPP_HIDE_FROM_ABI constexpr bool __enable_explicit() {
             return __tuple_constructible<_Tuple, pair>::value
                && !__tuple_convertible<_Tuple, pair>::value;
         }
 
         template <class _Tuple>
-        static constexpr bool __enable_assign() {
+        static _LIBCPP_HIDE_FROM_ABI constexpr bool __enable_assign() {
             return __tuple_assignable<_Tuple, pair>::value;
         }
     };
index 963e5e0..d2f8526 100644 (file)
@@ -325,7 +325,7 @@ private:
       const void* __fallback_info);
 
     union _Storage {
-        constexpr _Storage() : __ptr(nullptr) {}
+        _LIBCPP_HIDE_FROM_ABI constexpr _Storage() : __ptr(nullptr) {}
         void *  __ptr;
         __any_imp::_Buffer __buf;
     };
index cdabc06..58e0fb2 100644 (file)
@@ -233,14 +233,14 @@ struct _LIBCPP_TEMPLATE_VIS array
         return __elems_[__n];
     }
 
-    _LIBCPP_CONSTEXPR_SINCE_CXX17 reference at(size_type __n)
+    _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX17 reference at(size_type __n)
     {
         if (__n >= _Size)
             __throw_out_of_range("array::at");
         return __elems_[__n];
     }
 
-    _LIBCPP_CONSTEXPR_SINCE_CXX14 const_reference at(size_type __n) const
+    _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX14 const_reference at(size_type __n) const
     {
         if (__n >= _Size)
             __throw_out_of_range("array::at");
index ebaff8b..2ef232d 100644 (file)
@@ -124,7 +124,7 @@ class __barrier_base {
 public:
     using arrival_token = __barrier_phase_t;
 
-    static constexpr ptrdiff_t max() noexcept {
+    static _LIBCPP_HIDE_FROM_ABI constexpr ptrdiff_t max() noexcept {
         return numeric_limits<ptrdiff_t>::max();
     }
 
@@ -293,7 +293,7 @@ class barrier {
 public:
     using arrival_token = typename __barrier_base<_CompletionF>::arrival_token;
 
-    static constexpr ptrdiff_t max() noexcept {
+    static _LIBCPP_HIDE_FROM_ABI constexpr ptrdiff_t max() noexcept {
         return __barrier_base<_CompletionF>::max();
     }
 
index 4135a20..825114b 100644 (file)
@@ -199,7 +199,7 @@ condition_variable_any::notify_all() _NOEXCEPT
 struct __lock_external
 {
     template <class _Lock>
-    void operator()(_Lock* __m) {__m->lock();}
+    _LIBCPP_HIDE_FROM_ABI void operator()(_Lock* __m) {__m->lock();}
 };
 
 template <class _Lock>
index e47314a..a5e3dff 100644 (file)
@@ -82,15 +82,15 @@ public:
     typedef void                                 pointer;
     typedef void                                 reference;
 
-    ostream_joiner(ostream_type& __os, _Delim&& __d)
+    _LIBCPP_HIDE_FROM_ABI ostream_joiner(ostream_type& __os, _Delim&& __d)
         : __output_iter_(_VSTD::addressof(__os)), __delim_(_VSTD::move(__d)), __first_(true) {}
 
-    ostream_joiner(ostream_type& __os, const _Delim& __d)
+    _LIBCPP_HIDE_FROM_ABI ostream_joiner(ostream_type& __os, const _Delim& __d)
         : __output_iter_(_VSTD::addressof(__os)), __delim_(__d), __first_(true) {}
 
 
     template<typename _Tp>
-    ostream_joiner& operator=(const _Tp& __v)
+    _LIBCPP_HIDE_FROM_ABI ostream_joiner& operator=(const _Tp& __v)
     {
         if (!__first_)
             *__output_iter_ << __delim_;
@@ -99,9 +99,9 @@ public:
         return *this;
     }
 
-    ostream_joiner& operator*()     _NOEXCEPT { return *this; }
-    ostream_joiner& operator++()    _NOEXCEPT { return *this; }
-    ostream_joiner& operator++(int) _NOEXCEPT { return *this; }
+    _LIBCPP_HIDE_FROM_ABI ostream_joiner& operator*()     _NOEXCEPT { return *this; }
+    _LIBCPP_HIDE_FROM_ABI ostream_joiner& operator++()    _NOEXCEPT { return *this; }
+    _LIBCPP_HIDE_FROM_ABI ostream_joiner& operator++(int) _NOEXCEPT { return *this; }
 
 private:
     ostream_type*   __output_iter_;
index dcb61e3..4dc9845 100644 (file)
@@ -106,7 +106,7 @@ class _LIBCPP_DEPCREATED_MEMORY_RESOURCE("memory_resource") _LIBCPP_TYPE_VIS mem
 
 // 8.5.2, memory.resource.public
 public:
-    virtual ~memory_resource() = default;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual ~memory_resource() = default;
 
     _LIBCPP_INLINE_VISIBILITY
     void* allocate(size_t __bytes, size_t __align = __max_align)
@@ -174,7 +174,7 @@ public:
       : __res_(__r)
     {}
 
-    polymorphic_allocator(polymorphic_allocator const &) = default;
+    _LIBCPP_HIDE_FROM_ABI polymorphic_allocator(polymorphic_allocator const &) = default;
 
     template <class _Tp>
     _LIBCPP_INLINE_VISIBILITY
@@ -362,9 +362,9 @@ class _LIBCPP_TEMPLATE_VIS __resource_adaptor_imp
 public:
     typedef _CharAlloc allocator_type;
 
-    __resource_adaptor_imp() = default;
-    __resource_adaptor_imp(__resource_adaptor_imp const &) = default;
-    __resource_adaptor_imp(__resource_adaptor_imp &&) = default;
+    _LIBCPP_HIDE_FROM_ABI __resource_adaptor_imp() = default;
+    _LIBCPP_HIDE_FROM_ABI __resource_adaptor_imp(__resource_adaptor_imp const &) = default;
+    _LIBCPP_HIDE_FROM_ABI __resource_adaptor_imp(__resource_adaptor_imp &&) = default;
 
     // 8.7.2, memory.resource.adaptor.ctor
 
@@ -378,7 +378,7 @@ public:
       : __alloc_(_VSTD::move(__a))
     {}
 
-    __resource_adaptor_imp &
+    _LIBCPP_HIDE_FROM_ABI __resource_adaptor_imp &
     operator=(__resource_adaptor_imp const &) = default;
 
     _LIBCPP_INLINE_VISIBILITY
@@ -387,7 +387,7 @@ public:
 
 // 8.7.3, memory.resource.adaptor.mem
 private:
-    void * do_allocate(size_t __bytes, size_t) override
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL void * do_allocate(size_t __bytes, size_t) override
     {
         if (__bytes > __max_size())
             __throw_bad_array_new_length();
@@ -395,7 +395,7 @@ private:
         return __alloc_.allocate(__s);
     }
 
-    void do_deallocate(void * __p, size_t __bytes, size_t) override
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL void do_deallocate(void * __p, size_t __bytes, size_t) override
     {
         _LIBCPP_ASSERT(__bytes <= __max_size(),
             "do_deallocate called for size which exceeds the maximum allocation size");
@@ -403,7 +403,7 @@ private:
         __alloc_.deallocate((_ValueType*)__p, __s);
     }
 
-    bool do_is_equal(memory_resource const & __other) const _NOEXCEPT override {
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL bool do_is_equal(memory_resource const & __other) const _NOEXCEPT override {
         __resource_adaptor_imp const * __p
           = dynamic_cast<__resource_adaptor_imp const *>(&__other);
         return __p  ? __alloc_ == __p->__alloc_ : false;
index 3efec5d..acdc16c 100644 (file)
@@ -167,25 +167,25 @@ public:
 
 private:
   template <class _Up>
-  static _LIBCPP_CONSTEXPR element_type* __get_pointer(_Up* __u)
+  static _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR element_type* __get_pointer(_Up* __u)
   {
     return __u;
   }
 
   template <class _Up>
-  static _LIBCPP_CONSTEXPR element_type* __get_pointer(_Up& __u)
+  static _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR element_type* __get_pointer(_Up& __u)
   {
     return __get_pointer(__u.get());
   }
 
   template <class _Up>
-  static _LIBCPP_CONSTEXPR const element_type* __get_pointer(const _Up* __u)
+  static _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR const element_type* __get_pointer(const _Up* __u)
   {
     return __u;
   }
 
   template <class _Up>
-  static _LIBCPP_CONSTEXPR const element_type* __get_pointer(const _Up& __u)
+  static _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR const element_type* __get_pointer(const _Up& __u)
   {
     return __get_pointer(__u.get());
   }
@@ -207,22 +207,22 @@ public:
   template <class _Up> friend _LIBCPP_CONSTEXPR const _Up& ::_VSTD_LFTS_V2::get_underlying(const propagate_const<_Up>& __pu) _NOEXCEPT;
   template <class _Up> friend _LIBCPP_CONSTEXPR _Up& ::_VSTD_LFTS_V2::get_underlying(propagate_const<_Up>& __pu) _NOEXCEPT;
 
-  _LIBCPP_CONSTEXPR propagate_const() = default;
+  _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR propagate_const() = default;
 
   propagate_const(const propagate_const&) = delete;
 
-  _LIBCPP_CONSTEXPR propagate_const(propagate_const&&) = default;
+  _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR propagate_const(propagate_const&&) = default;
 
   template <class _Up, enable_if_t<!is_convertible<_Up, _Tp>::value &&
                                  is_constructible<_Tp, _Up&&>::value,bool> = true>
-  explicit _LIBCPP_CONSTEXPR propagate_const(propagate_const<_Up>&& __pu)
+  explicit _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR propagate_const(propagate_const<_Up>&& __pu)
       : __t_(std::move(_VSTD_LFTS_V2::get_underlying(__pu)))
   {
   }
 
   template <class _Up, enable_if_t<is_convertible<_Up&&, _Tp>::value &&
                                  is_constructible<_Tp, _Up&&>::value,bool> = false>
-  _LIBCPP_CONSTEXPR propagate_const(propagate_const<_Up>&& __pu)
+  _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR propagate_const(propagate_const<_Up>&& __pu)
       : __t_(std::move(_VSTD_LFTS_V2::get_underlying(__pu)))
   {
   }
@@ -230,7 +230,7 @@ public:
   template <class _Up, enable_if_t<!is_convertible<_Up&&, _Tp>::value &&
                                  is_constructible<_Tp, _Up&&>::value &&
                                  !__is_propagate_const<decay_t<_Up>>::value,bool> = true>
-  explicit _LIBCPP_CONSTEXPR propagate_const(_Up&& __u)
+  explicit _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR propagate_const(_Up&& __u)
       : __t_(std::forward<_Up>(__u))
   {
   }
@@ -238,78 +238,78 @@ public:
   template <class _Up, enable_if_t<is_convertible<_Up&&, _Tp>::value &&
                                  is_constructible<_Tp, _Up&&>::value &&
                                  !__is_propagate_const<decay_t<_Up>>::value,bool> = false>
-  _LIBCPP_CONSTEXPR propagate_const(_Up&& __u)
+  _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR propagate_const(_Up&& __u)
       : __t_(std::forward<_Up>(__u))
   {
   }
 
   propagate_const& operator=(const propagate_const&) = delete;
 
-  _LIBCPP_CONSTEXPR propagate_const& operator=(propagate_const&&) = default;
+  _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR propagate_const& operator=(propagate_const&&) = default;
 
   template <class _Up>
-  _LIBCPP_CONSTEXPR propagate_const& operator=(propagate_const<_Up>&& __pu)
+  _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR propagate_const& operator=(propagate_const<_Up>&& __pu)
   {
     __t_ = std::move(_VSTD_LFTS_V2::get_underlying(__pu));
     return *this;
   }
 
   template <class _Up, class _Vp = enable_if_t<!__is_propagate_const<decay_t<_Up>>::value>>
-  _LIBCPP_CONSTEXPR propagate_const& operator=(_Up&& __u)
+  _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR propagate_const& operator=(_Up&& __u)
   {
     __t_ = std::forward<_Up>(__u);
     return *this;
   }
 
-  _LIBCPP_CONSTEXPR const element_type* get() const
+  _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR const element_type* get() const
   {
     return __get_pointer(__t_);
   }
 
-  _LIBCPP_CONSTEXPR element_type* get()
+  _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR element_type* get()
   {
     return __get_pointer(__t_);
   }
 
-  explicit _LIBCPP_CONSTEXPR operator bool() const
+  _LIBCPP_HIDE_FROM_ABI explicit _LIBCPP_CONSTEXPR operator bool() const
   {
     return get() != nullptr;
   }
 
-  _LIBCPP_CONSTEXPR const element_type* operator->() const
+  _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR const element_type* operator->() const
   {
     return get();
   }
 
   template <class _Tp_ = _Tp, class _Up = enable_if_t<is_convertible<
                                   const _Tp_, const element_type *>::value>>
-  _LIBCPP_CONSTEXPR operator const element_type *() const {
+  _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR operator const element_type *() const {
     return get();
   }
 
-  _LIBCPP_CONSTEXPR const element_type& operator*() const
+  _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR const element_type& operator*() const
   {
     return *get();
   }
 
-  _LIBCPP_CONSTEXPR element_type* operator->()
+  _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR element_type* operator->()
   {
     return get();
   }
 
   template <class _Tp_ = _Tp, class _Up = enable_if_t<
                                   is_convertible<_Tp_, element_type *>::value>>
-  _LIBCPP_CONSTEXPR operator element_type *() {
+  _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR operator element_type *() {
     return get();
   }
 
-  _LIBCPP_CONSTEXPR element_type& operator*()
+  _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR element_type& operator*()
   {
     return *get();
   }
 
-  _LIBCPP_CONSTEXPR void swap(propagate_const& __pt) _NOEXCEPT_(__is_nothrow_swappable<_Tp>::value)
-  {
+  _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR void swap(propagate_const& __pt)
+      _NOEXCEPT_(__is_nothrow_swappable<_Tp>::value) {
     using _VSTD::swap;
     swap(__t_, __pt.__t_);
   }
@@ -506,7 +506,7 @@ struct hash<experimental::fundamentals_v2::propagate_const<_Tp>>
   typedef size_t result_type;
   typedef experimental::fundamentals_v2::propagate_const<_Tp> argument_type;
 
-  size_t operator()(const experimental::fundamentals_v2::propagate_const<_Tp>& __pc1) const
+  _LIBCPP_HIDE_FROM_ABI size_t operator()(const experimental::fundamentals_v2::propagate_const<_Tp>& __pc1) const
   {
     return std::hash<_Tp>()(_VSTD_LFTS_V2::get_underlying(__pc1));
   }
@@ -518,7 +518,7 @@ struct equal_to<experimental::fundamentals_v2::propagate_const<_Tp>>
   typedef experimental::fundamentals_v2::propagate_const<_Tp> first_argument_type;
   typedef experimental::fundamentals_v2::propagate_const<_Tp> second_argument_type;
 
-  bool operator()(const experimental::fundamentals_v2::propagate_const<_Tp>& __pc1,
+  _LIBCPP_HIDE_FROM_ABI bool operator()(const experimental::fundamentals_v2::propagate_const<_Tp>& __pc1,
       const experimental::fundamentals_v2::propagate_const<_Tp>& __pc2) const
   {
     return std::equal_to<_Tp>()(_VSTD_LFTS_V2::get_underlying(__pc1), _VSTD_LFTS_V2::get_underlying(__pc2));
@@ -531,7 +531,7 @@ struct not_equal_to<experimental::fundamentals_v2::propagate_const<_Tp>>
   typedef experimental::fundamentals_v2::propagate_const<_Tp> first_argument_type;
   typedef experimental::fundamentals_v2::propagate_const<_Tp> second_argument_type;
 
-  bool operator()(const experimental::fundamentals_v2::propagate_const<_Tp>& __pc1,
+  _LIBCPP_HIDE_FROM_ABI bool operator()(const experimental::fundamentals_v2::propagate_const<_Tp>& __pc1,
       const experimental::fundamentals_v2::propagate_const<_Tp>& __pc2) const
   {
     return std::not_equal_to<_Tp>()(_VSTD_LFTS_V2::get_underlying(__pc1), _VSTD_LFTS_V2::get_underlying(__pc2));
@@ -544,7 +544,7 @@ struct less<experimental::fundamentals_v2::propagate_const<_Tp>>
   typedef experimental::fundamentals_v2::propagate_const<_Tp> first_argument_type;
   typedef experimental::fundamentals_v2::propagate_const<_Tp> second_argument_type;
 
-  bool operator()(const experimental::fundamentals_v2::propagate_const<_Tp>& __pc1,
+  _LIBCPP_HIDE_FROM_ABI bool operator()(const experimental::fundamentals_v2::propagate_const<_Tp>& __pc1,
       const experimental::fundamentals_v2::propagate_const<_Tp>& __pc2) const
   {
     return std::less<_Tp>()(_VSTD_LFTS_V2::get_underlying(__pc1), _VSTD_LFTS_V2::get_underlying(__pc2));
@@ -557,7 +557,7 @@ struct greater<experimental::fundamentals_v2::propagate_const<_Tp>>
   typedef experimental::fundamentals_v2::propagate_const<_Tp> first_argument_type;
   typedef experimental::fundamentals_v2::propagate_const<_Tp> second_argument_type;
 
-  bool operator()(const experimental::fundamentals_v2::propagate_const<_Tp>& __pc1,
+  _LIBCPP_HIDE_FROM_ABI bool operator()(const experimental::fundamentals_v2::propagate_const<_Tp>& __pc1,
       const experimental::fundamentals_v2::propagate_const<_Tp>& __pc2) const
   {
     return std::greater<_Tp>()(_VSTD_LFTS_V2::get_underlying(__pc1), _VSTD_LFTS_V2::get_underlying(__pc2));
@@ -570,7 +570,7 @@ struct less_equal<experimental::fundamentals_v2::propagate_const<_Tp>>
   typedef experimental::fundamentals_v2::propagate_const<_Tp> first_argument_type;
   typedef experimental::fundamentals_v2::propagate_const<_Tp> second_argument_type;
 
-  bool operator()(const experimental::fundamentals_v2::propagate_const<_Tp>& __pc1,
+  _LIBCPP_HIDE_FROM_ABI bool operator()(const experimental::fundamentals_v2::propagate_const<_Tp>& __pc1,
       const experimental::fundamentals_v2::propagate_const<_Tp>& __pc2) const
   {
     return std::less_equal<_Tp>()(_VSTD_LFTS_V2::get_underlying(__pc1), _VSTD_LFTS_V2::get_underlying(__pc2));
@@ -583,7 +583,7 @@ struct greater_equal<experimental::fundamentals_v2::propagate_const<_Tp>>
   typedef experimental::fundamentals_v2::propagate_const<_Tp> first_argument_type;
   typedef experimental::fundamentals_v2::propagate_const<_Tp> second_argument_type;
 
-  bool operator()(const experimental::fundamentals_v2::propagate_const<_Tp>& __pc1,
+  _LIBCPP_HIDE_FROM_ABI bool operator()(const experimental::fundamentals_v2::propagate_const<_Tp>& __pc1,
       const experimental::fundamentals_v2::propagate_const<_Tp>& __pc2) const
   {
     return std::greater_equal<_Tp>()(_VSTD_LFTS_V2::get_underlying(__pc1), _VSTD_LFTS_V2::get_underlying(__pc2));
index 4ca67d2..11047d1 100644 (file)
@@ -691,8 +691,8 @@ class __simd_storage<_Tp, __simd_abi<_StorageKind::_Array, __num_element>> {
   friend struct simd_mask;
 
 public:
-  _Tp __get(size_t __index) const noexcept { return __storage_[__index]; }
-  void __set(size_t __index, _Tp __val) noexcept {
+  _LIBCPP_HIDE_FROM_ABI _Tp __get(size_t __index) const noexcept { return __storage_[__index]; }
+  _LIBCPP_HIDE_FROM_ABI void __set(size_t __index, _Tp __val) noexcept {
     __storage_[__index] = __val;
   }
 };
@@ -708,8 +708,8 @@ class __simd_storage<_Tp, __simd_abi<_StorageKind::_Scalar, 1>> {
   friend struct simd_mask;
 
 public:
-  _Tp __get(size_t __index) const noexcept { return (&__storage_)[__index]; }
-  void __set(size_t __index, _Tp __val) noexcept {
+  _LIBCPP_HIDE_FROM_ABI _Tp __get(size_t __index) const noexcept { return (&__storage_)[__index]; }
+  _LIBCPP_HIDE_FROM_ABI void __set(size_t __index, _Tp __val) noexcept {
     (&__storage_)[__index] = __val;
   }
 };
@@ -810,8 +810,8 @@ class __simd_storage<_Tp, __simd_abi<_StorageKind::_VecExt, __num_element>> {
   friend struct simd_mask;
 
 public:
-  _Tp __get(size_t __index) const noexcept { return __storage_[__index]; }
-  void __set(size_t __index, _Tp __val) noexcept {
+  _LIBCPP_HIDE_FROM_ABI _Tp __get(size_t __index) const noexcept { return __storage_[__index]; }
+  _LIBCPP_HIDE_FROM_ABI void __set(size_t __index, _Tp __val) noexcept {
     __storage_[__index] = __val;
   }
 };
@@ -831,79 +831,79 @@ class __simd_reference {
   __simd_storage<_Tp, _Abi>* __ptr_;
   size_t __index_;
 
-  __simd_reference(__simd_storage<_Tp, _Abi>* __ptr, size_t __index)
+  _LIBCPP_HIDE_FROM_ABI __simd_reference(__simd_storage<_Tp, _Abi>* __ptr, size_t __index)
       : __ptr_(__ptr), __index_(__index) {}
 
-  __simd_reference(const __simd_reference&) = default;
+  _LIBCPP_HIDE_FROM_ABI __simd_reference(const __simd_reference&) = default;
 
 public:
   __simd_reference() = delete;
   __simd_reference& operator=(const __simd_reference&) = delete;
 
-  operator _Vp() const { return __ptr_->__get(__index_); }
+  _LIBCPP_HIDE_FROM_ABI operator _Vp() const { return __ptr_->__get(__index_); }
 
-  __simd_reference operator=(_Vp __value) && {
+  _LIBCPP_HIDE_FROM_ABI __simd_reference operator=(_Vp __value) && {
     __ptr_->__set(__index_, __value);
     return *this;
   }
 
-  __simd_reference operator++() && {
+  _LIBCPP_HIDE_FROM_ABI __simd_reference operator++() && {
     return std::move(*this) = __ptr_->__get(__index_) + 1;
   }
 
-  _Vp operator++(int) && {
+  _LIBCPP_HIDE_FROM_ABI _Vp operator++(int) && {
     auto __val = __ptr_->__get(__index_);
     __ptr_->__set(__index_, __val + 1);
     return __val;
   }
 
-  __simd_reference operator--() && {
+  _LIBCPP_HIDE_FROM_ABI __simd_reference operator--() && {
     return std::move(*this) = __ptr_->__get(__index_) - 1;
   }
 
-  _Vp operator--(int) && {
+  _LIBCPP_HIDE_FROM_ABI _Vp operator--(int) && {
     auto __val = __ptr_->__get(__index_);
     __ptr_->__set(__index_, __val - 1);
     return __val;
   }
 
-  __simd_reference operator+=(_Vp __value) && {
+  _LIBCPP_HIDE_FROM_ABI __simd_reference operator+=(_Vp __value) && {
     return std::move(*this) = __ptr_->__get(__index_) + __value;
   }
 
-  __simd_reference operator-=(_Vp __value) && {
+  _LIBCPP_HIDE_FROM_ABI __simd_reference operator-=(_Vp __value) && {
     return std::move(*this) = __ptr_->__get(__index_) - __value;
   }
 
-  __simd_reference operator*=(_Vp __value) && {
+  _LIBCPP_HIDE_FROM_ABI __simd_reference operator*=(_Vp __value) && {
     return std::move(*this) = __ptr_->__get(__index_) * __value;
   }
 
-  __simd_reference operator/=(_Vp __value) && {
+  _LIBCPP_HIDE_FROM_ABI __simd_reference operator/=(_Vp __value) && {
     return std::move(*this) = __ptr_->__get(__index_) / __value;
   }
 
-  __simd_reference operator%=(_Vp __value) && {
+  _LIBCPP_HIDE_FROM_ABI __simd_reference operator%=(_Vp __value) && {
     return std::move(*this) = __ptr_->__get(__index_) % __value;
   }
 
-  __simd_reference operator>>=(_Vp __value) && {
+  _LIBCPP_HIDE_FROM_ABI __simd_reference operator>>=(_Vp __value) && {
     return std::move(*this) = __ptr_->__get(__index_) >> __value;
   }
 
-  __simd_reference operator<<=(_Vp __value) && {
+  _LIBCPP_HIDE_FROM_ABI __simd_reference operator<<=(_Vp __value) && {
     return std::move(*this) = __ptr_->__get(__index_) << __value;
   }
 
-  __simd_reference operator&=(_Vp __value) && {
+  _LIBCPP_HIDE_FROM_ABI __simd_reference operator&=(_Vp __value) && {
     return std::move(*this) = __ptr_->__get(__index_) & __value;
   }
 
-  __simd_reference operator|=(_Vp __value) && {
+  _LIBCPP_HIDE_FROM_ABI __simd_reference operator|=(_Vp __value) && {
     return std::move(*this) = __ptr_->__get(__index_) | __value;
   }
 
-  __simd_reference operator^=(_Vp __value) && {
+  _LIBCPP_HIDE_FROM_ABI __simd_reference operator^=(_Vp __value) && {
     return std::move(*this) = __ptr_->__get(__index_) ^ __value;
   }
 };
@@ -1350,11 +1350,11 @@ public:
   using mask_type = simd_mask<_Tp, _Abi>;
   using abi_type = _Abi;
 
-  simd() = default;
-  simd(const simd&) = default;
-  simd& operator=(const simd&) = default;
+  _LIBCPP_HIDE_FROM_ABI simd() = default;
+  _LIBCPP_HIDE_FROM_ABI simd(const simd&) = default;
+  _LIBCPP_HIDE_FROM_ABI simd& operator=(const simd&) = default;
 
-  static constexpr size_t size() noexcept {
+  static _LIBCPP_HIDE_FROM_ABI constexpr size_t size() noexcept {
     return simd_size<_Tp, _Abi>::value;
   }
 
@@ -1362,7 +1362,7 @@ private:
   __simd_storage<_Tp, _Abi> __s_;
 
   template <class _Up>
-  static constexpr bool __can_broadcast() {
+  static _LIBCPP_HIDE_FROM_ABI constexpr bool __can_broadcast() {
     return (std::is_arithmetic<_Up>::value &&
             __is_non_narrowing_arithmetic_convertible<_Up, _Tp>()) ||
            (!std::is_arithmetic<_Up>::value &&
@@ -1374,7 +1374,7 @@ private:
   }
 
   template <class _Generator, size_t... __indicies>
-  static constexpr decltype(
+  static _LIBCPP_HIDE_FROM_ABI constexpr decltype(
       std::forward_as_tuple(std::declval<_Generator>()(
           std::integral_constant<size_t, __indicies>())...),
       bool())
@@ -1385,12 +1385,12 @@ private:
   }
 
   template <class _Generator>
-  static bool __can_generate(...) {
+  static _LIBCPP_HIDE_FROM_ABI bool __can_generate(...) {
     return false;
   }
 
   template <class _Generator, size_t... __indicies>
-  void __generator_init(_Generator&& __g, std::index_sequence<__indicies...>) {
+  _LIBCPP_HIDE_FROM_ABI void __generator_init(_Generator&& __g, std::index_sequence<__indicies...>) {
     int __not_used[]{((*this)[__indicies] =
                           __g(std::integral_constant<size_t, __indicies>()),
                       0)...};
@@ -1403,7 +1403,7 @@ public:
             class = typename std::enable_if<
                 std::is_same<_Abi, simd_abi::fixed_size<size()>>::value &&
                 __is_non_narrowing_arithmetic_convertible<_Up, _Tp>()>::type>
-  simd(const simd<_Up, simd_abi::fixed_size<size()>>& __v) {
+  _LIBCPP_HIDE_FROM_ABI simd(const simd<_Up, simd_abi::fixed_size<size()>>& __v) {
     for (size_t __i = 0; __i < size(); __i++) {
       (*this)[__i] = static_cast<_Tp>(__v[__i]);
     }
@@ -1412,7 +1412,7 @@ public:
   // implicit broadcast constructor
   template <class _Up,
             class = typename std::enable_if<__can_broadcast<_Up>()>::type>
-  simd(_Up&& __rv) {
+  _LIBCPP_HIDE_FROM_ABI simd(_Up&& __rv) {
     auto __v = static_cast<_Tp>(__rv);
     for (size_t __i = 0; __i < size(); __i++) {
       (*this)[__i] = __v;
@@ -1424,7 +1424,7 @@ public:
             int = typename std::enable_if<
                 __can_generate<_Generator>(std::make_index_sequence<size()>()),
                 int>::type()>
-  explicit simd(_Generator&& __g) {
+  explicit _LIBCPP_HIDE_FROM_ABI simd(_Generator&& __g) {
     __generator_init(std::forward<_Generator>(__g),
                      std::make_index_sequence<size()>());
   }
@@ -1434,7 +1434,7 @@ public:
       class _Up, class _Flags,
       class = typename std::enable_if<__vectorizable<_Up>()>::type,
       class = typename std::enable_if<is_simd_flag_type<_Flags>::value>::type>
-  simd(const _Up* __buffer, _Flags) {
+  _LIBCPP_HIDE_FROM_ABI simd(const _Up* __buffer, _Flags) {
     // TODO: optimize for overaligned flags
     for (size_t __i = 0; __i < size(); __i++) {
       (*this)[__i] = static_cast<_Tp>(__buffer[__i]);
@@ -1445,7 +1445,7 @@ public:
   template <class _Up, class _Flags>
   typename std::enable_if<__vectorizable<_Up>() &&
                           is_simd_flag_type<_Flags>::value>::type
-  copy_from(const _Up* __buffer, _Flags) {
+  _LIBCPP_HIDE_FROM_ABI copy_from(const _Up* __buffer, _Flags) {
     *this = simd(__buffer, _Flags());
   }
 
@@ -1453,7 +1453,7 @@ public:
   template <class _Up, class _Flags>
   typename std::enable_if<__vectorizable<_Up>() &&
                           is_simd_flag_type<_Flags>::value>::type
-  copy_to(_Up* __buffer, _Flags) const {
+  _LIBCPP_HIDE_FROM_ABI copy_to(_Up* __buffer, _Flags) const {
     // TODO: optimize for overaligned flags
     for (size_t __i = 0; __i < size(); __i++) {
       __buffer[__i] = static_cast<_Up>((*this)[__i]);
@@ -1461,9 +1461,9 @@ public:
   }
 
   // scalar access [simd.subscr]
-  reference operator[](size_t __i) { return reference(&__s_, __i); }
+  _LIBCPP_HIDE_FROM_ABI reference operator[](size_t __i) { return reference(&__s_, __i); }
 
-  value_type operator[](size_t __i) const { return __s_.__get(__i); }
+  _LIBCPP_HIDE_FROM_ABI value_type operator[](size_t __i) const { return __s_.__get(__i); }
 
   // unary operators [simd.unary]
   simd& operator++();
@@ -1526,7 +1526,7 @@ public:
   using simd_type = simd<_Tp, _Abi>;
   using abi_type = _Abi;
   static constexpr size_t size() noexcept;
-  simd_mask() = default;
+  _LIBCPP_HIDE_FROM_ABI simd_mask() = default;
 
   // broadcast constructor
   explicit simd_mask(value_type) noexcept;
index f7f53bc..116b6a7 100644 (file)
@@ -323,7 +323,7 @@ public:
     bool __first_constructed;
     bool __second_constructed;
 
-    __hash_map_node_destructor(__hash_map_node_destructor const&) = default;
+    _LIBCPP_HIDE_FROM_ABI __hash_map_node_destructor(__hash_map_node_destructor const&) = default;
     __hash_map_node_destructor& operator=(const __hash_map_node_destructor&) = delete;
 
     _LIBCPP_INLINE_VISIBILITY
@@ -507,23 +507,23 @@ public:
     typedef __hash_map_const_iterator<typename __table::const_iterator> const_iterator;
 
     _LIBCPP_INLINE_VISIBILITY hash_map() { }
-    explicit hash_map(size_type __n, const hasher& __hf = hasher(),
+    explicit _LIBCPP_HIDE_FROM_ABI hash_map(size_type __n, const hasher& __hf = hasher(),
                            const key_equal& __eql = key_equal());
-    hash_map(size_type __n, const hasher& __hf,
+    _LIBCPP_HIDE_FROM_ABI hash_map(size_type __n, const hasher& __hf,
                   const key_equal& __eql,
                   const allocator_type& __a);
     template <class _InputIterator>
-        hash_map(_InputIterator __first, _InputIterator __last);
+    _LIBCPP_HIDE_FROM_ABI hash_map(_InputIterator __first, _InputIterator __last);
     template <class _InputIterator>
-        hash_map(_InputIterator __first, _InputIterator __last,
+    _LIBCPP_HIDE_FROM_ABI hash_map(_InputIterator __first, _InputIterator __last,
                       size_type __n, const hasher& __hf = hasher(),
                       const key_equal& __eql = key_equal());
     template <class _InputIterator>
-        hash_map(_InputIterator __first, _InputIterator __last,
+    _LIBCPP_HIDE_FROM_ABI hash_map(_InputIterator __first, _InputIterator __last,
                       size_type __n, const hasher& __hf,
                       const key_equal& __eql,
                       const allocator_type& __a);
-    hash_map(const hash_map& __u);
+    _LIBCPP_HIDE_FROM_ABI hash_map(const hash_map& __u);
 
     _LIBCPP_INLINE_VISIBILITY
     allocator_type get_allocator() const
@@ -587,7 +587,7 @@ public:
     std::pair<const_iterator, const_iterator> equal_range(const key_type& __k) const
         {return __table_.__equal_range_unique(__k);}
 
-    mapped_type& operator[](const key_type& __k);
+    _LIBCPP_HIDE_FROM_ABI mapped_type& operator[](const key_type& __k);
 
     _LIBCPP_INLINE_VISIBILITY
     size_type bucket_count() const {return __table_.bucket_count();}
@@ -602,7 +602,7 @@ public:
     void resize(size_type __n) {__table_.__rehash_unique(__n);}
 
 private:
-    __node_holder __construct_node(const key_type& __k);
+    _LIBCPP_HIDE_FROM_ABI __node_holder __construct_node(const key_type& __k);
 };
 
 template <class _Key, class _Tp, class _Hash, class _Pred, class _Alloc>
@@ -779,23 +779,23 @@ public:
 
     _LIBCPP_INLINE_VISIBILITY
     hash_multimap() { }
-    explicit hash_multimap(size_type __n, const hasher& __hf = hasher(),
+    explicit _LIBCPP_HIDE_FROM_ABI hash_multimap(size_type __n, const hasher& __hf = hasher(),
                                 const key_equal& __eql = key_equal());
-    hash_multimap(size_type __n, const hasher& __hf,
+    _LIBCPP_HIDE_FROM_ABI hash_multimap(size_type __n, const hasher& __hf,
                                 const key_equal& __eql,
                                 const allocator_type& __a);
     template <class _InputIterator>
-        hash_multimap(_InputIterator __first, _InputIterator __last);
+    _LIBCPP_HIDE_FROM_ABI hash_multimap(_InputIterator __first, _InputIterator __last);
     template <class _InputIterator>
-        hash_multimap(_InputIterator __first, _InputIterator __last,
+    _LIBCPP_HIDE_FROM_ABI hash_multimap(_InputIterator __first, _InputIterator __last,
                       size_type __n, const hasher& __hf = hasher(),
                       const key_equal& __eql = key_equal());
     template <class _InputIterator>
-        hash_multimap(_InputIterator __first, _InputIterator __last,
+    _LIBCPP_HIDE_FROM_ABI hash_multimap(_InputIterator __first, _InputIterator __last,
                       size_type __n, const hasher& __hf,
                       const key_equal& __eql,
                       const allocator_type& __a);
-    hash_multimap(const hash_multimap& __u);
+    _LIBCPP_HIDE_FROM_ABI hash_multimap(const hash_multimap& __u);
 
     _LIBCPP_INLINE_VISIBILITY
     allocator_type get_allocator() const
index 9c67862..c0c2ba2 100644 (file)
@@ -244,21 +244,21 @@ public:
 
     _LIBCPP_INLINE_VISIBILITY
     hash_set() { }
-    explicit hash_set(size_type __n, const hasher& __hf = hasher(),
+    _LIBCPP_HIDE_FROM_ABI explicit hash_set(size_type __n, const hasher& __hf = hasher(),
                            const key_equal& __eql = key_equal());
-    hash_set(size_type __n, const hasher& __hf, const key_equal& __eql,
+    _LIBCPP_HIDE_FROM_ABI hash_set(size_type __n, const hasher& __hf, const key_equal& __eql,
                   const allocator_type& __a);
     template <class _InputIterator>
-        hash_set(_InputIterator __first, _InputIterator __last);
+    _LIBCPP_HIDE_FROM_ABI hash_set(_InputIterator __first, _InputIterator __last);
     template <class _InputIterator>
-        hash_set(_InputIterator __first, _InputIterator __last,
+    _LIBCPP_HIDE_FROM_ABI hash_set(_InputIterator __first, _InputIterator __last,
                       size_type __n, const hasher& __hf = hasher(),
                       const key_equal& __eql = key_equal());
     template <class _InputIterator>
-        hash_set(_InputIterator __first, _InputIterator __last,
+    _LIBCPP_HIDE_FROM_ABI hash_set(_InputIterator __first, _InputIterator __last,
                       size_type __n, const hasher& __hf, const key_equal& __eql,
                       const allocator_type& __a);
-    hash_set(const hash_set& __u);
+    _LIBCPP_HIDE_FROM_ABI hash_set(const hash_set& __u);
 
     _LIBCPP_INLINE_VISIBILITY
     allocator_type get_allocator() const
@@ -465,21 +465,21 @@ public:
 
     _LIBCPP_INLINE_VISIBILITY
     hash_multiset() { }
-    explicit hash_multiset(size_type __n, const hasher& __hf = hasher(),
+    explicit _LIBCPP_HIDE_FROM_ABI hash_multiset(size_type __n, const hasher& __hf = hasher(),
                                 const key_equal& __eql = key_equal());
-    hash_multiset(size_type __n, const hasher& __hf,
+    _LIBCPP_HIDE_FROM_ABI hash_multiset(size_type __n, const hasher& __hf,
                        const key_equal& __eql, const allocator_type& __a);
     template <class _InputIterator>
-        hash_multiset(_InputIterator __first, _InputIterator __last);
+    _LIBCPP_HIDE_FROM_ABI hash_multiset(_InputIterator __first, _InputIterator __last);
     template <class _InputIterator>
-        hash_multiset(_InputIterator __first, _InputIterator __last,
+    _LIBCPP_HIDE_FROM_ABI hash_multiset(_InputIterator __first, _InputIterator __last,
                       size_type __n, const hasher& __hf = hasher(),
                       const key_equal& __eql = key_equal());
     template <class _InputIterator>
-        hash_multiset(_InputIterator __first, _InputIterator __last,
+    _LIBCPP_HIDE_FROM_ABI hash_multiset(_InputIterator __first, _InputIterator __last,
                       size_type __n , const hasher& __hf,
                       const key_equal& __eql, const allocator_type& __a);
-    hash_multiset(const hash_multiset& __u);
+    _LIBCPP_HIDE_FROM_ABI hash_multiset(const hash_multiset& __u);
 
     _LIBCPP_INLINE_VISIBILITY
     allocator_type get_allocator() const
index ad616d1..03c1f1b 100644 (file)
@@ -407,11 +407,11 @@ class _LIBCPP_TEMPLATE_VIS __forward_list_const_iterator
 
     __iter_node_pointer __ptr_;
 
-    __begin_node_pointer __get_begin() const {
+    _LIBCPP_HIDE_FROM_ABI __begin_node_pointer __get_begin() const {
         return static_cast<__begin_node_pointer>(
                 static_cast<__void_pointer>(__ptr_));
     }
-    __node_pointer __get_unsafe_node_pointer() const {
+    _LIBCPP_HIDE_FROM_ABI __node_pointer __get_unsafe_node_pointer() const {
         return static_cast<__node_pointer>(
                 static_cast<__void_pointer>(__ptr_));
     }
@@ -537,7 +537,7 @@ private:
     __forward_list_base& operator=(const __forward_list_base&);
 
 public:
-    ~__forward_list_base();
+    _LIBCPP_HIDE_FROM_ABI ~__forward_list_base();
 
 protected:
     _LIBCPP_INLINE_VISIBILITY
@@ -562,7 +562,7 @@ public:
                     __is_nothrow_swappable<__node_allocator>::value);
 #endif
 protected:
-    void clear() _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI void clear() _NOEXCEPT;
 
 private:
     _LIBCPP_INLINE_VISIBILITY
@@ -695,39 +695,39 @@ public:
         {} // = default;
     _LIBCPP_INLINE_VISIBILITY
     explicit forward_list(const allocator_type& __a);
-    explicit forward_list(size_type __n);
+    _LIBCPP_HIDE_FROM_ABI explicit forward_list(size_type __n);
 #if _LIBCPP_STD_VER >= 14
-    explicit forward_list(size_type __n, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI explicit forward_list(size_type __n, const allocator_type& __a);
 #endif
-    forward_list(size_type __n, const value_type& __v);
+    _LIBCPP_HIDE_FROM_ABI forward_list(size_type __n, const value_type& __v);
 
     template <class = __enable_if_t<__is_allocator<_Alloc>::value> >
-    forward_list(size_type __n, const value_type& __v, const allocator_type& __a) : base(__a)
+    _LIBCPP_HIDE_FROM_ABI forward_list(size_type __n, const value_type& __v, const allocator_type& __a) : base(__a)
     {
         insert_after(cbefore_begin(), __n, __v);
     }
 
     template <class _InputIterator>
-        forward_list(_InputIterator __f, _InputIterator __l,
+    _LIBCPP_HIDE_FROM_ABI forward_list(_InputIterator __f, _InputIterator __l,
                      __enable_if_t<__is_cpp17_input_iterator<_InputIterator>::value>* = nullptr);
     template <class _InputIterator>
-        forward_list(_InputIterator __f, _InputIterator __l,
+    _LIBCPP_HIDE_FROM_ABI forward_list(_InputIterator __f, _InputIterator __l,
                      const allocator_type& __a,
                      __enable_if_t<__is_cpp17_input_iterator<_InputIterator>::value>* = nullptr);
-    forward_list(const forward_list& __x);
-    forward_list(const forward_list& __x, const __type_identity_t<allocator_type>& __a);
+    _LIBCPP_HIDE_FROM_ABI forward_list(const forward_list& __x);
+    _LIBCPP_HIDE_FROM_ABI forward_list(const forward_list& __x, const __type_identity_t<allocator_type>& __a);
 
-    forward_list& operator=(const forward_list& __x);
+    _LIBCPP_HIDE_FROM_ABI forward_list& operator=(const forward_list& __x);
 
 #ifndef _LIBCPP_CXX03_LANG
     _LIBCPP_INLINE_VISIBILITY
     forward_list(forward_list&& __x)
         _NOEXCEPT_(is_nothrow_move_constructible<base>::value)
         : base(_VSTD::move(__x)) {}
-    forward_list(forward_list&& __x, const __type_identity_t<allocator_type>& __a);
+    _LIBCPP_HIDE_FROM_ABI forward_list(forward_list&& __x, const __type_identity_t<allocator_type>& __a);
 
-    forward_list(initializer_list<value_type> __il);
-    forward_list(initializer_list<value_type> __il, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI forward_list(initializer_list<value_type> __il);
+    _LIBCPP_HIDE_FROM_ABI forward_list(initializer_list<value_type> __il, const allocator_type& __a);
 
     _LIBCPP_INLINE_VISIBILITY
     forward_list& operator=(forward_list&& __x)
@@ -746,8 +746,8 @@ public:
 
     template <class _InputIterator>
     __enable_if_t<__is_cpp17_input_iterator<_InputIterator>::value, void>
-        assign(_InputIterator __f, _InputIterator __l);
-    void assign(size_type __n, const value_type& __v);
+    _LIBCPP_HIDE_FROM_ABI assign(_InputIterator __f, _InputIterator __l);
+    _LIBCPP_HIDE_FROM_ABI void assign(size_type __n, const value_type& __v);
 
     _LIBCPP_INLINE_VISIBILITY
     allocator_type get_allocator() const _NOEXCEPT
@@ -800,33 +800,35 @@ public:
 
 #ifndef _LIBCPP_CXX03_LANG
 #if _LIBCPP_STD_VER >= 17
-    template <class... _Args> reference emplace_front(_Args&&... __args);
+    template <class... _Args>
+    _LIBCPP_HIDE_FROM_ABI reference emplace_front(_Args&&... __args);
 #else
-    template <class... _Args> void      emplace_front(_Args&&... __args);
+    template <class... _Args>
+    _LIBCPP_HIDE_FROM_ABI void      emplace_front(_Args&&... __args);
 #endif
-    void push_front(value_type&& __v);
+    _LIBCPP_HIDE_FROM_ABI void push_front(value_type&& __v);
 #endif // _LIBCPP_CXX03_LANG
-    void push_front(const value_type& __v);
+    _LIBCPP_HIDE_FROM_ABI void push_front(const value_type& __v);
 
-    void pop_front();
+    _LIBCPP_HIDE_FROM_ABI void pop_front();
 
 #ifndef _LIBCPP_CXX03_LANG
     template <class... _Args>
-        iterator emplace_after(const_iterator __p, _Args&&... __args);
+    _LIBCPP_HIDE_FROM_ABI iterator emplace_after(const_iterator __p, _Args&&... __args);
 
-    iterator insert_after(const_iterator __p, value_type&& __v);
-    iterator insert_after(const_iterator __p, initializer_list<value_type> __il)
+    _LIBCPP_HIDE_FROM_ABI iterator insert_after(const_iterator __p, value_type&& __v);
+    _LIBCPP_HIDE_FROM_ABI iterator insert_after(const_iterator __p, initializer_list<value_type> __il)
         {return insert_after(__p, __il.begin(), __il.end());}
 #endif // _LIBCPP_CXX03_LANG
-    iterator insert_after(const_iterator __p, const value_type& __v);
-    iterator insert_after(const_iterator __p, size_type __n, const value_type& __v);
+    _LIBCPP_HIDE_FROM_ABI iterator insert_after(const_iterator __p, const value_type& __v);
+    _LIBCPP_HIDE_FROM_ABI iterator insert_after(const_iterator __p, size_type __n, const value_type& __v);
     template <class _InputIterator>
     _LIBCPP_INLINE_VISIBILITY
     __enable_if_t<__is_cpp17_input_iterator<_InputIterator>::value, iterator>
         insert_after(const_iterator __p, _InputIterator __f, _InputIterator __l);
 
-    iterator erase_after(const_iterator __p);
-    iterator erase_after(const_iterator __f, const_iterator __l);
+    _LIBCPP_HIDE_FROM_ABI iterator erase_after(const_iterator __p);
+    _LIBCPP_HIDE_FROM_ABI iterator erase_after(const_iterator __f, const_iterator __l);
 
     _LIBCPP_INLINE_VISIBILITY
     void swap(forward_list& __x)
@@ -838,8 +840,8 @@ public:
 #endif
         {base::swap(__x);}
 
-    void resize(size_type __n);
-    void resize(size_type __n, const value_type& __v);
+    _LIBCPP_HIDE_FROM_ABI void resize(size_type __n);
+    _LIBCPP_HIDE_FROM_ABI void resize(size_type __n, const value_type& __v);
     _LIBCPP_INLINE_VISIBILITY
     void clear() _NOEXCEPT {base::clear();}
 
@@ -850,15 +852,17 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     void splice_after(const_iterator __p, forward_list&& __x,
                       const_iterator __f, const_iterator __l);
-    void splice_after(const_iterator __p, forward_list& __x);
-    void splice_after(const_iterator __p, forward_list& __x, const_iterator __i);
-    void splice_after(const_iterator __p, forward_list& __x,
+    _LIBCPP_HIDE_FROM_ABI void splice_after(const_iterator __p, forward_list& __x);
+    _LIBCPP_HIDE_FROM_ABI void splice_after(const_iterator __p, forward_list& __x, const_iterator __i);
+    _LIBCPP_HIDE_FROM_ABI void splice_after(const_iterator __p, forward_list& __x,
                       const_iterator __f, const_iterator __l);
-    __remove_return_type remove(const value_type& __v);
-    template <class _Predicate> __remove_return_type remove_if(_Predicate __pred);
+    _LIBCPP_HIDE_FROM_ABI __remove_return_type remove(const value_type& __v);
+    template <class _Predicate>
+    _LIBCPP_HIDE_FROM_ABI __remove_return_type remove_if(_Predicate __pred);
     _LIBCPP_INLINE_VISIBILITY
     __remove_return_type unique() { return unique(__equal_to()); }
-    template <class _BinaryPredicate> __remove_return_type unique(_BinaryPredicate __binary_pred);
+    template <class _BinaryPredicate>
+    _LIBCPP_HIDE_FROM_ABI __remove_return_type unique(_BinaryPredicate __binary_pred);
 #ifndef _LIBCPP_CXX03_LANG
     _LIBCPP_INLINE_VISIBILITY
     void merge(forward_list&& __x) {merge(__x, __less<value_type>());}
@@ -869,27 +873,29 @@ public:
 #endif // _LIBCPP_CXX03_LANG
     _LIBCPP_INLINE_VISIBILITY
     void merge(forward_list& __x) {merge(__x, __less<value_type>());}
-    template <class _Compare> void merge(forward_list& __x, _Compare __comp);
+    template <class _Compare>
+    _LIBCPP_HIDE_FROM_ABI void merge(forward_list& __x, _Compare __comp);
     _LIBCPP_INLINE_VISIBILITY
     void sort() {sort(__less<value_type>());}
     template <class _Compare> _LIBCPP_INLINE_VISIBILITY void sort(_Compare __comp);
-    void reverse() _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI void reverse() _NOEXCEPT;
 
 private:
 
 #ifndef _LIBCPP_CXX03_LANG
-    void __move_assign(forward_list& __x, true_type)
+    _LIBCPP_HIDE_FROM_ABI void __move_assign(forward_list& __x, true_type)
         _NOEXCEPT_(is_nothrow_move_assignable<allocator_type>::value);
-    void __move_assign(forward_list& __x, false_type);
+    _LIBCPP_HIDE_FROM_ABI void __move_assign(forward_list& __x, false_type);
 #endif // _LIBCPP_CXX03_LANG
 
     template <class _Compare>
-        static
+    static _LIBCPP_HIDE_FROM_ABI
         __node_pointer
         __merge(__node_pointer __f1, __node_pointer __f2, _Compare& __comp);
 
+    // TODO: Make this _LIBCPP_HIDE_FROM_ABI
     template <class _Compare>
-        static
+    static _LIBCPP_HIDDEN
         __node_pointer
         __sort(__node_pointer __f, difference_type __sz, _Compare& __comp);
 };
index 09deccf..a312d18 100644 (file)
@@ -1588,11 +1588,11 @@ public:
     basic_filebuf<char_type, traits_type>* rdbuf() const;
     _LIBCPP_INLINE_VISIBILITY
     bool is_open() const;
-    void open(const char* __s, ios_base::openmode __mode = ios_base::in | ios_base::out);
+    _LIBCPP_HIDE_FROM_ABI void open(const char* __s, ios_base::openmode __mode = ios_base::in | ios_base::out);
 #ifdef _LIBCPP_HAS_OPEN_WITH_WCHAR
     void open(const wchar_t* __s, ios_base::openmode __mode = ios_base::in | ios_base::out);
 #endif
-    void open(const string& __s, ios_base::openmode __mode = ios_base::in | ios_base::out);
+    _LIBCPP_HIDE_FROM_ABI void open(const string& __s, ios_base::openmode __mode = ios_base::in | ios_base::out);
 
 #if _LIBCPP_STD_VER >= 17 && !defined(_LIBCPP_HAS_NO_FILESYSTEM_LIBRARY)
     _LIBCPP_AVAILABILITY_FILESYSTEM _LIBCPP_INLINE_VISIBILITY
index 22fc585..1f17aae 100644 (file)
@@ -526,7 +526,7 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     const error_code& code() const _NOEXCEPT {return __ec_;}
 
-    future_error(const future_error&) _NOEXCEPT = default;
+    _LIBCPP_HIDE_FROM_ABI future_error(const future_error&) _NOEXCEPT = default;
     ~future_error() _NOEXCEPT override;
 };
 
@@ -642,17 +642,17 @@ _LIBCPP_SUPPRESS_DEPRECATED_POP
 protected:
     _Up __value_;
 
-    void __on_zero_shared() _NOEXCEPT override;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL void __on_zero_shared() _NOEXCEPT override;
 public:
 
     template <class _Arg>
-    void set_value(_Arg&& __arg);
+    _LIBCPP_HIDE_FROM_ABI void set_value(_Arg&& __arg);
 
     template <class _Arg>
-    void set_value_at_thread_exit(_Arg&& __arg);
+    _LIBCPP_HIDE_FROM_ABI void set_value_at_thread_exit(_Arg&& __arg);
 
-    _Rp move();
-    __add_lvalue_reference_t<_Rp> copy();
+    _LIBCPP_HIDE_FROM_ABI _Rp move();
+    _LIBCPP_HIDE_FROM_ABI __add_lvalue_reference_t<_Rp> copy();
 };
 
 template <class _Rp>
@@ -722,13 +722,13 @@ class _LIBCPP_AVAILABILITY_FUTURE __assoc_state<_Rp&>
 protected:
     _Up __value_;
 
-    void __on_zero_shared() _NOEXCEPT override;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL void __on_zero_shared() _NOEXCEPT override;
 public:
 
-    void set_value(_Rp& __arg);
-    void set_value_at_thread_exit(_Rp& __arg);
+    _LIBCPP_HIDE_FROM_ABI void set_value(_Rp& __arg);
+    _LIBCPP_HIDE_FROM_ABI void set_value_at_thread_exit(_Rp& __arg);
 
-    _Rp& copy();
+    _LIBCPP_HIDE_FROM_ABI _Rp& copy();
 };
 
 template <class _Rp>
@@ -780,7 +780,7 @@ class _LIBCPP_AVAILABILITY_FUTURE __assoc_state_alloc
     typedef __assoc_state<_Rp> base;
     _Alloc __alloc_;
 
-    virtual void __on_zero_shared() _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __on_zero_shared() _NOEXCEPT;
 public:
     _LIBCPP_INLINE_VISIBILITY
     explicit __assoc_state_alloc(const _Alloc& __a)
@@ -808,7 +808,7 @@ class _LIBCPP_AVAILABILITY_FUTURE __assoc_state_alloc<_Rp&, _Alloc>
     typedef __assoc_state<_Rp&> base;
     _Alloc __alloc_;
 
-    virtual void __on_zero_shared() _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __on_zero_shared() _NOEXCEPT;
 public:
     _LIBCPP_INLINE_VISIBILITY
     explicit __assoc_state_alloc(const _Alloc& __a)
@@ -834,7 +834,7 @@ class _LIBCPP_AVAILABILITY_FUTURE __assoc_sub_state_alloc
     typedef __assoc_sub_state base;
     _Alloc __alloc_;
 
-    void __on_zero_shared() _NOEXCEPT override;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL void __on_zero_shared() _NOEXCEPT override;
 public:
     _LIBCPP_INLINE_VISIBILITY
     explicit __assoc_sub_state_alloc(const _Alloc& __a)
@@ -865,7 +865,7 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     explicit __deferred_assoc_state(_Fp&& __f);
 
-    virtual void __execute();
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __execute();
 };
 
 template <class _Rp, class _Fp>
@@ -906,7 +906,7 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     explicit __deferred_assoc_state(_Fp&& __f);
 
-    void __execute() override;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL void __execute() override;
 };
 
 template <class _Fp>
@@ -944,12 +944,12 @@ class _LIBCPP_AVAILABILITY_FUTURE __async_assoc_state
 
     _Fp __func_;
 
-    virtual void __on_zero_shared() _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __on_zero_shared() _NOEXCEPT;
 public:
     _LIBCPP_INLINE_VISIBILITY
     explicit __async_assoc_state(_Fp&& __f);
 
-    virtual void __execute();
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __execute();
 };
 
 template <class _Rp, class _Fp>
@@ -993,12 +993,12 @@ class _LIBCPP_AVAILABILITY_FUTURE __async_assoc_state<void, _Fp>
 
     _Fp __func_;
 
-    void __on_zero_shared() _NOEXCEPT override;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL void __on_zero_shared() _NOEXCEPT override;
 public:
     _LIBCPP_INLINE_VISIBILITY
     explicit __async_assoc_state(_Fp&& __f);
 
-    void __execute() override;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL void __execute() override;
 };
 
 template <class _Fp>
@@ -1055,7 +1055,7 @@ class _LIBCPP_TEMPLATE_VIS _LIBCPP_AVAILABILITY_FUTURE future
 {
     __assoc_state<_Rp>* __state_;
 
-    explicit future(__assoc_state<_Rp>* __state);
+    explicit _LIBCPP_HIDE_FROM_ABI future(__assoc_state<_Rp>* __state);
 
     template <class> friend class promise;
     template <class> friend class shared_future;
@@ -1080,12 +1080,12 @@ public:
             return *this;
         }
 
-    ~future();
+    _LIBCPP_HIDE_FROM_ABI ~future();
     _LIBCPP_INLINE_VISIBILITY
     shared_future<_Rp> share() _NOEXCEPT;
 
     // retrieving the value
-    _Rp get();
+    _LIBCPP_HIDE_FROM_ABI _Rp get();
 
     _LIBCPP_INLINE_VISIBILITY
     void swap(future& __rhs) _NOEXCEPT {_VSTD::swap(__state_, __rhs.__state_);}
@@ -1117,7 +1117,7 @@ future<_Rp>::future(__assoc_state<_Rp>* __state)
 
 struct __release_shared_count
 {
-    void operator()(__shared_count* __p) {__p->__release_shared();}
+    _LIBCPP_HIDE_FROM_ABI void operator()(__shared_count* __p) {__p->__release_shared();}
 };
 
 template <class _Rp>
@@ -1142,7 +1142,7 @@ class _LIBCPP_TEMPLATE_VIS _LIBCPP_AVAILABILITY_FUTURE future<_Rp&>
 {
     __assoc_state<_Rp&>* __state_;
 
-    explicit future(__assoc_state<_Rp&>* __state);
+    explicit _LIBCPP_HIDE_FROM_ABI future(__assoc_state<_Rp&>* __state);
 
     template <class> friend class promise;
     template <class> friend class shared_future;
@@ -1167,12 +1167,12 @@ public:
             return *this;
         }
 
-    ~future();
+    _LIBCPP_HIDE_FROM_ABI ~future();
     _LIBCPP_INLINE_VISIBILITY
     shared_future<_Rp&> share() _NOEXCEPT;
 
     // retrieving the value
-    _Rp& get();
+    _LIBCPP_HIDE_FROM_ABI _Rp& get();
 
     _LIBCPP_INLINE_VISIBILITY
     void swap(future& __rhs) _NOEXCEPT {_VSTD::swap(__state_, __rhs.__state_);}
@@ -1299,14 +1299,14 @@ class _LIBCPP_TEMPLATE_VIS _LIBCPP_AVAILABILITY_FUTURE promise
 
     template <class> friend class packaged_task;
 public:
-    promise();
+    _LIBCPP_HIDE_FROM_ABI promise();
     template <class _Alloc>
-        promise(allocator_arg_t, const _Alloc& __a);
+    _LIBCPP_HIDE_FROM_ABI promise(allocator_arg_t, const _Alloc& __a);
     _LIBCPP_INLINE_VISIBILITY
     promise(promise&& __rhs) _NOEXCEPT
         : __state_(__rhs.__state_) {__rhs.__state_ = nullptr;}
     promise(const promise& __rhs) = delete;
-    ~promise();
+    _LIBCPP_HIDE_FROM_ABI ~promise();
 
     // assignment
     _LIBCPP_INLINE_VISIBILITY
@@ -1321,17 +1321,17 @@ public:
     void swap(promise& __rhs) _NOEXCEPT {_VSTD::swap(__state_, __rhs.__state_);}
 
     // retrieving the result
-    future<_Rp> get_future();
+    _LIBCPP_HIDE_FROM_ABI future<_Rp> get_future();
 
     // setting the result
-    void set_value(const _Rp& __r);
-    void set_value(_Rp&& __r);
-    void set_exception(exception_ptr __p);
+    _LIBCPP_HIDE_FROM_ABI void set_value(const _Rp& __r);
+    _LIBCPP_HIDE_FROM_ABI void set_value(_Rp&& __r);
+    _LIBCPP_HIDE_FROM_ABI void set_exception(exception_ptr __p);
 
     // setting the result with deferred notification
-    void set_value_at_thread_exit(const _Rp& __r);
-    void set_value_at_thread_exit(_Rp&& __r);
-    void set_exception_at_thread_exit(exception_ptr __p);
+    _LIBCPP_HIDE_FROM_ABI void set_value_at_thread_exit(const _Rp& __r);
+    _LIBCPP_HIDE_FROM_ABI void set_value_at_thread_exit(_Rp&& __r);
+    _LIBCPP_HIDE_FROM_ABI void set_exception_at_thread_exit(exception_ptr __p);
 };
 
 template <class _Rp>
@@ -1444,14 +1444,14 @@ class _LIBCPP_TEMPLATE_VIS _LIBCPP_AVAILABILITY_FUTURE promise<_Rp&>
     template <class> friend class packaged_task;
 
 public:
-    promise();
+    _LIBCPP_HIDE_FROM_ABI promise();
     template <class _Allocator>
-        promise(allocator_arg_t, const _Allocator& __a);
+    _LIBCPP_HIDE_FROM_ABI promise(allocator_arg_t, const _Allocator& __a);
     _LIBCPP_INLINE_VISIBILITY
     promise(promise&& __rhs) _NOEXCEPT
         : __state_(__rhs.__state_) {__rhs.__state_ = nullptr;}
     promise(const promise& __rhs) = delete;
-    ~promise();
+    _LIBCPP_HIDE_FROM_ABI ~promise();
 
     // assignment
     _LIBCPP_INLINE_VISIBILITY
@@ -1466,15 +1466,15 @@ public:
     void swap(promise& __rhs) _NOEXCEPT {_VSTD::swap(__state_, __rhs.__state_);}
 
     // retrieving the result
-    future<_Rp&> get_future();
+    _LIBCPP_HIDE_FROM_ABI future<_Rp&> get_future();
 
     // setting the result
-    void set_value(_Rp& __r);
-    void set_exception(exception_ptr __p);
+    _LIBCPP_HIDE_FROM_ABI void set_value(_Rp& __r);
+    _LIBCPP_HIDE_FROM_ABI void set_exception(exception_ptr __p);
 
     // setting the result with deferred notification
-    void set_value_at_thread_exit(_Rp&);
-    void set_exception_at_thread_exit(exception_ptr __p);
+    _LIBCPP_HIDE_FROM_ABI void set_value_at_thread_exit(_Rp&);
+    _LIBCPP_HIDE_FROM_ABI void set_exception_at_thread_exit(exception_ptr __p);
 };
 
 template <class _Rp>
@@ -1665,10 +1665,10 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     __packaged_task_func(_Fp&& __f, const _Alloc& __a)
         : __f_(_VSTD::move(__f), __a) {}
-    virtual void __move_to(__packaged_task_base<_Rp(_ArgTypes...)>*) _NOEXCEPT;
-    virtual void destroy();
-    virtual void destroy_deallocate();
-    virtual _Rp operator()(_ArgTypes&& ... __args);
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __move_to(__packaged_task_base<_Rp(_ArgTypes...)>*) _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void destroy();
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void destroy_deallocate();
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual _Rp operator()(_ArgTypes&& ... __args);
 };
 
 template<class _Fp, class _Alloc, class _Rp, class ..._ArgTypes>
@@ -1727,22 +1727,22 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     __packaged_task_function() _NOEXCEPT : __f_(nullptr) {}
     template<class _Fp>
-      __packaged_task_function(_Fp&& __f);
+    _LIBCPP_HIDE_FROM_ABI __packaged_task_function(_Fp&& __f);
     template<class _Fp, class _Alloc>
-      __packaged_task_function(allocator_arg_t, const _Alloc& __a, _Fp&& __f);
+    _LIBCPP_HIDE_FROM_ABI __packaged_task_function(allocator_arg_t, const _Alloc& __a, _Fp&& __f);
 
-    __packaged_task_function(__packaged_task_function&&) _NOEXCEPT;
-    __packaged_task_function& operator=(__packaged_task_function&&) _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI __packaged_task_function(__packaged_task_function&&) _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI __packaged_task_function& operator=(__packaged_task_function&&) _NOEXCEPT;
 
     __packaged_task_function(const __packaged_task_function&) =  delete;
     __packaged_task_function& operator=(const __packaged_task_function&) =  delete;
 
-    ~__packaged_task_function();
+    _LIBCPP_HIDE_FROM_ABI ~__packaged_task_function();
 
-    void swap(__packaged_task_function&) _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI void swap(__packaged_task_function&) _NOEXCEPT;
 
     _LIBCPP_INLINE_VISIBILITY
-    _Rp operator()(_ArgTypes...) const;
+    _LIBCPP_HIDE_FROM_ABI _Rp operator()(_ArgTypes...) const;
 };
 
 template<class _Rp, class ..._ArgTypes>
@@ -1947,10 +1947,10 @@ public:
     future<result_type> get_future() {return __p_.get_future();}
 
     // execution
-    void operator()(_ArgTypes... __args);
-    void make_ready_at_thread_exit(_ArgTypes... __args);
+    _LIBCPP_HIDE_FROM_ABI void operator()(_ArgTypes... __args);
+    _LIBCPP_HIDE_FROM_ABI void make_ready_at_thread_exit(_ArgTypes... __args);
 
-    void reset();
+    _LIBCPP_HIDE_FROM_ABI void reset();
 };
 
 template<class _Rp, class ..._ArgTypes>
@@ -2062,10 +2062,10 @@ public:
     future<result_type> get_future() {return __p_.get_future();}
 
     // execution
-    void operator()(_ArgTypes... __args);
-    void make_ready_at_thread_exit(_ArgTypes... __args);
+    _LIBCPP_HIDE_FROM_ABI void operator()(_ArgTypes... __args);
+    _LIBCPP_HIDE_FROM_ABI void make_ready_at_thread_exit(_ArgTypes... __args);
 
-    void reset();
+    _LIBCPP_HIDE_FROM_ABI void reset();
 };
 
 #if _LIBCPP_STD_VER >= 17
@@ -2181,14 +2181,14 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     __async_func(__async_func&& __f) : __f_(_VSTD::move(__f.__f_)) {}
 
-    _Rp operator()()
+    _LIBCPP_HIDE_FROM_ABI _Rp operator()()
     {
         typedef typename __make_tuple_indices<1+sizeof...(_Args), 1>::type _Index;
         return __execute(_Index());
     }
 private:
     template <size_t ..._Indices>
-    _Rp
+    _LIBCPP_HIDE_FROM_ABI _Rp
     __execute(__tuple_indices<_Indices...>)
     {
         return _VSTD::__invoke(_VSTD::move(_VSTD::get<0>(__f_)), _VSTD::move(_VSTD::get<_Indices>(__f_))...);
@@ -2254,8 +2254,8 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     shared_future(shared_future&& __rhs) _NOEXCEPT : __state_(__rhs.__state_)
         {__rhs.__state_ = nullptr;}
-    ~shared_future();
-    shared_future& operator=(const shared_future& __rhs) _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI ~shared_future();
+    _LIBCPP_HIDE_FROM_ABI shared_future& operator=(const shared_future& __rhs) _NOEXCEPT;
     _LIBCPP_INLINE_VISIBILITY
     shared_future& operator=(shared_future&& __rhs) _NOEXCEPT
         {
@@ -2324,8 +2324,8 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     shared_future(shared_future&& __rhs) _NOEXCEPT : __state_(__rhs.__state_)
         {__rhs.__state_ = nullptr;}
-    ~shared_future();
-    shared_future& operator=(const shared_future& __rhs);
+    _LIBCPP_HIDE_FROM_ABI ~shared_future();
+    _LIBCPP_HIDE_FROM_ABI shared_future& operator=(const shared_future& __rhs);
     _LIBCPP_INLINE_VISIBILITY
     shared_future& operator=(shared_future&& __rhs) _NOEXCEPT
         {
index d972a22..c97daac 100644 (file)
@@ -446,7 +446,7 @@ class _LIBCPP_EXCEPTION_ABI ios_base::failure
 public:
     explicit failure(const string& __msg, const error_code& __ec = io_errc::stream);
     explicit failure(const char* __msg, const error_code& __ec = io_errc::stream);
-    failure(const failure&) _NOEXCEPT = default;
+    _LIBCPP_HIDE_FROM_ABI failure(const failure&) _NOEXCEPT = default;
     ~failure() _NOEXCEPT override;
 };
 
index d72cb4f..8e1309e 100644 (file)
@@ -70,14 +70,14 @@ class latch
     __atomic_base<ptrdiff_t> __a_;
 
 public:
-    static constexpr ptrdiff_t max() noexcept {
+    static _LIBCPP_HIDE_FROM_ABI constexpr ptrdiff_t max() noexcept {
         return numeric_limits<ptrdiff_t>::max();
     }
 
     inline _LIBCPP_INLINE_VISIBILITY
     constexpr explicit latch(ptrdiff_t __expected) : __a_(__expected) { }
 
-    ~latch() = default;
+    _LIBCPP_HIDE_FROM_ABI ~latch() = default;
     latch(const latch&) = delete;
     latch& operator=(const latch&) = delete;
 
index 6969d3c..4f3818d 100644 (file)
@@ -614,10 +614,10 @@ protected:
     _LIBCPP_INLINE_VISIBILITY
     __list_imp(const __node_allocator& __a);
 #ifndef _LIBCPP_CXX03_LANG
-    __list_imp(__node_allocator&& __a) _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI __list_imp(__node_allocator&& __a) _NOEXCEPT;
 #endif
-    ~__list_imp();
-    void clear() _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI ~__list_imp();
+    _LIBCPP_HIDE_FROM_ABI void clear() _NOEXCEPT;
     _LIBCPP_INLINE_VISIBILITY
     bool empty() const _NOEXCEPT {return __sz() == 0;}
 
@@ -642,7 +642,7 @@ protected:
         return const_iterator(__end_as_link(), this);
     }
 
-    void swap(__list_imp& __c)
+    _LIBCPP_HIDE_FROM_ABI void swap(__list_imp& __c)
 #if _LIBCPP_STD_VER >= 14
         _NOEXCEPT;
 #else
@@ -866,13 +866,13 @@ public:
     {
         _VSTD::__debug_db_insert_c(this);
     }
-    explicit list(size_type __n);
+    _LIBCPP_HIDE_FROM_ABI explicit list(size_type __n);
 #if _LIBCPP_STD_VER >= 14
-    explicit list(size_type __n, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI explicit list(size_type __n, const allocator_type& __a);
 #endif
-    list(size_type __n, const value_type& __x);
+    _LIBCPP_HIDE_FROM_ABI list(size_type __n, const value_type& __x);
     template <class = __enable_if_t<__is_allocator<_Alloc>::value> >
-    list(size_type __n, const value_type& __x, const allocator_type& __a) : base(__a)
+    _LIBCPP_HIDE_FROM_ABI list(size_type __n, const value_type& __x, const allocator_type& __a) : base(__a)
     {
         _VSTD::__debug_db_insert_c(this);
         for (; __n > 0; --__n)
@@ -880,19 +880,19 @@ public:
     }
 
     template <class _InpIter>
-        list(_InpIter __f, _InpIter __l,
+    _LIBCPP_HIDE_FROM_ABI list(_InpIter __f, _InpIter __l,
              __enable_if_t<__is_cpp17_input_iterator<_InpIter>::value>* = 0);
     template <class _InpIter>
-        list(_InpIter __f, _InpIter __l, const allocator_type& __a,
+    _LIBCPP_HIDE_FROM_ABI list(_InpIter __f, _InpIter __l, const allocator_type& __a,
              __enable_if_t<__is_cpp17_input_iterator<_InpIter>::value>* = 0);
 
-    list(const list& __c);
-    list(const list& __c, const __type_identity_t<allocator_type>& __a);
+    _LIBCPP_HIDE_FROM_ABI list(const list& __c);
+    _LIBCPP_HIDE_FROM_ABI list(const list& __c, const __type_identity_t<allocator_type>& __a);
     _LIBCPP_INLINE_VISIBILITY
     list& operator=(const list& __c);
 #ifndef _LIBCPP_CXX03_LANG
-    list(initializer_list<value_type> __il);
-    list(initializer_list<value_type> __il, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI list(initializer_list<value_type> __il);
+    _LIBCPP_HIDE_FROM_ABI list(initializer_list<value_type> __il, const allocator_type& __a);
 
     _LIBCPP_INLINE_VISIBILITY
     list(list&& __c)
@@ -915,9 +915,9 @@ public:
 #endif // _LIBCPP_CXX03_LANG
 
     template <class _InpIter>
-        void assign(_InpIter __f, _InpIter __l,
+    _LIBCPP_HIDE_FROM_ABI void assign(_InpIter __f, _InpIter __l,
                     __enable_if_t<__is_cpp17_input_iterator<_InpIter>::value>* = 0);
-    void assign(size_type __n, const value_type& __x);
+    _LIBCPP_HIDE_FROM_ABI void assign(size_type __n, const value_type& __x);
 
     _LIBCPP_INLINE_VISIBILITY
     allocator_type get_allocator() const _NOEXCEPT;
@@ -992,33 +992,33 @@ public:
     }
 
 #ifndef _LIBCPP_CXX03_LANG
-    void push_front(value_type&& __x);
-    void push_back(value_type&& __x);
+    _LIBCPP_HIDE_FROM_ABI void push_front(value_type&& __x);
+    _LIBCPP_HIDE_FROM_ABI void push_back(value_type&& __x);
 
     template <class... _Args>
 #if _LIBCPP_STD_VER >= 17
-       reference emplace_front(_Args&&... __args);
+    _LIBCPP_HIDE_FROM_ABI reference emplace_front(_Args&&... __args);
 #else
-       void      emplace_front(_Args&&... __args);
+    _LIBCPP_HIDE_FROM_ABI void      emplace_front(_Args&&... __args);
 #endif
     template <class... _Args>
 #if _LIBCPP_STD_VER >= 17
-        reference emplace_back(_Args&&... __args);
+    _LIBCPP_HIDE_FROM_ABI reference emplace_back(_Args&&... __args);
 #else
-       void       emplace_back(_Args&&... __args);
+    _LIBCPP_HIDE_FROM_ABI void       emplace_back(_Args&&... __args);
 #endif
     template <class... _Args>
-        iterator emplace(const_iterator __p, _Args&&... __args);
+    _LIBCPP_HIDE_FROM_ABI iterator emplace(const_iterator __p, _Args&&... __args);
 
-    iterator insert(const_iterator __p, value_type&& __x);
+    _LIBCPP_HIDE_FROM_ABI iterator insert(const_iterator __p, value_type&& __x);
 
     _LIBCPP_INLINE_VISIBILITY
     iterator insert(const_iterator __p, initializer_list<value_type> __il)
         {return insert(__p, __il.begin(), __il.end());}
 #endif // _LIBCPP_CXX03_LANG
 
-    void push_front(const value_type& __x);
-    void push_back(const value_type& __x);
+    _LIBCPP_HIDE_FROM_ABI void push_front(const value_type& __x);
+    _LIBCPP_HIDE_FROM_ABI void push_back(const value_type& __x);
 
 #ifndef _LIBCPP_CXX03_LANG
     template <class _Arg>
@@ -1029,10 +1029,10 @@ public:
     void __emplace_back(value_type const& __arg) { push_back(__arg); }
 #endif
 
-    iterator insert(const_iterator __p, const value_type& __x);
-    iterator insert(const_iterator __p, size_type __n, const value_type& __x);
+    _LIBCPP_HIDE_FROM_ABI iterator insert(const_iterator __p, const value_type& __x);
+    _LIBCPP_HIDE_FROM_ABI iterator insert(const_iterator __p, size_type __n, const value_type& __x);
     template <class _InpIter>
-        iterator insert(const_iterator __p, _InpIter __f, _InpIter __l,
+    _LIBCPP_HIDE_FROM_ABI iterator insert(const_iterator __p, _InpIter __f, _InpIter __l,
                         __enable_if_t<__is_cpp17_input_iterator<_InpIter>::value>* = 0);
 
     _LIBCPP_INLINE_VISIBILITY
@@ -1047,16 +1047,16 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     void clear() _NOEXCEPT {base::clear();}
 
-    void pop_front();
-    void pop_back();
+    _LIBCPP_HIDE_FROM_ABI void pop_front();
+    _LIBCPP_HIDE_FROM_ABI void pop_back();
 
-    iterator erase(const_iterator __p);
-    iterator erase(const_iterator __f, const_iterator __l);
+    _LIBCPP_HIDE_FROM_ABI iterator erase(const_iterator __p);
+    _LIBCPP_HIDE_FROM_ABI iterator erase(const_iterator __f, const_iterator __l);
 
-    void resize(size_type __n);
-    void resize(size_type __n, const value_type& __x);
+    _LIBCPP_HIDE_FROM_ABI void resize(size_type __n);
+    _LIBCPP_HIDE_FROM_ABI void resize(size_type __n, const value_type& __x);
 
-    void splice(const_iterator __p, list& __c);
+    _LIBCPP_HIDE_FROM_ABI void splice(const_iterator __p, list& __c);
 #ifndef _LIBCPP_CXX03_LANG
     _LIBCPP_INLINE_VISIBILITY
     void splice(const_iterator __p, list&& __c) {splice(__p, __c);}
@@ -1067,15 +1067,16 @@ public:
     void splice(const_iterator __p, list&& __c, const_iterator __f, const_iterator __l)
         {splice(__p, __c, __f, __l);}
 #endif
-    void splice(const_iterator __p, list& __c, const_iterator __i);
-    void splice(const_iterator __p, list& __c, const_iterator __f, const_iterator __l);
+    _LIBCPP_HIDE_FROM_ABI void splice(const_iterator __p, list& __c, const_iterator __i);
+    _LIBCPP_HIDE_FROM_ABI void splice(const_iterator __p, list& __c, const_iterator __f, const_iterator __l);
 
-    __remove_return_type remove(const value_type& __x);
-    template <class _Pred> __remove_return_type remove_if(_Pred __pred);
+    _LIBCPP_HIDE_FROM_ABI __remove_return_type remove(const value_type& __x);
+    template <class _Pred>
+    _LIBCPP_HIDE_FROM_ABI __remove_return_type remove_if(_Pred __pred);
     _LIBCPP_INLINE_VISIBILITY
     __remove_return_type unique() { return unique(__equal_to()); }
     template <class _BinaryPred>
-        __remove_return_type unique(_BinaryPred __binary_pred);
+    _LIBCPP_HIDE_FROM_ABI __remove_return_type unique(_BinaryPred __binary_pred);
     _LIBCPP_INLINE_VISIBILITY
     void merge(list& __c);
 #ifndef _LIBCPP_CXX03_LANG
@@ -1087,7 +1088,7 @@ public:
         void merge(list&& __c, _Comp __comp) {merge(__c, __comp);}
 #endif
     template <class _Comp>
-        void merge(list& __c, _Comp __comp);
+    _LIBCPP_HIDE_FROM_ABI void merge(list& __c, _Comp __comp);
 
     _LIBCPP_INLINE_VISIBILITY
     void sort();
@@ -1095,9 +1096,9 @@ public:
         _LIBCPP_INLINE_VISIBILITY
         void sort(_Comp __comp);
 
-    void reverse() _NOEXCEPT;
+    _LIBCPP_HIDE_FROM_ABI void reverse() _NOEXCEPT;
 
-    bool __invariants() const;
+    _LIBCPP_HIDE_FROM_ABI bool __invariants() const;
 
     typedef __allocator_destructor<__node_allocator> __node_destructor;
     typedef unique_ptr<__node, __node_destructor> __hold_pointer;
@@ -1125,13 +1126,14 @@ private:
     void __link_nodes_at_front(__link_pointer __f, __link_pointer __l);
     _LIBCPP_INLINE_VISIBILITY
     void __link_nodes_at_back (__link_pointer __f, __link_pointer __l);
-    iterator __iterator(size_type __n);
+    _LIBCPP_HIDE_FROM_ABI iterator __iterator(size_type __n);
+    // TODO: Make this _LIBCPP_HIDE_FROM_ABI
     template <class _Comp>
-        static iterator __sort(iterator __f1, iterator __e2, size_type __n, _Comp& __comp);
+    _LIBCPP_HIDDEN static iterator __sort(iterator __f1, iterator __e2, size_type __n, _Comp& __comp);
 
-    void __move_assign(list& __c, true_type)
+    _LIBCPP_HIDE_FROM_ABI void __move_assign(list& __c, true_type)
         _NOEXCEPT_(is_nothrow_move_assignable<__node_allocator>::value);
-    void __move_assign(list& __c, false_type);
+    _LIBCPP_HIDE_FROM_ABI void __move_assign(list& __c, false_type);
 };
 
 #if _LIBCPP_STD_VER >= 17
index 4b7e865..122d4bb 100644 (file)
@@ -3633,13 +3633,13 @@ public:
 
     _LIBCPP_INLINE_VISIBILITY
     wstring_convert(_Codecvt* __pcvt, state_type __state);
-    _LIBCPP_EXPLICIT_SINCE_CXX14 wstring_convert(const byte_string& __byte_err,
+    _LIBCPP_EXPLICIT_SINCE_CXX14 _LIBCPP_HIDE_FROM_ABI wstring_convert(const byte_string& __byte_err,
                     const wide_string& __wide_err = wide_string());
 #ifndef _LIBCPP_CXX03_LANG
     _LIBCPP_INLINE_VISIBILITY
     wstring_convert(wstring_convert&& __wc);
 #endif
-    ~wstring_convert();
+    _LIBCPP_HIDE_FROM_ABI ~wstring_convert();
 
     _LIBCPP_INLINE_VISIBILITY
     wide_string from_bytes(char __byte)
@@ -3650,7 +3650,7 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     wide_string from_bytes(const byte_string& __str)
         {return from_bytes(__str.data(), __str.data() + __str.size());}
-    wide_string from_bytes(const char* __first, const char* __last);
+    _LIBCPP_HIDE_FROM_ABI wide_string from_bytes(const char* __first, const char* __last);
 
     _LIBCPP_INLINE_VISIBILITY
     byte_string to_bytes(_Elem __wchar)
@@ -3661,7 +3661,7 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     byte_string to_bytes(const wide_string& __wstr)
         {return to_bytes(__wstr.data(), __wstr.data() + __wstr.size());}
-    byte_string to_bytes(const _Elem* __first, const _Elem* __last);
+    _LIBCPP_HIDE_FROM_ABI byte_string to_bytes(const _Elem* __first, const _Elem* __last);
 
     _LIBCPP_INLINE_VISIBILITY
     size_t converted() const _NOEXCEPT {return __cvtcount_;}
@@ -3904,18 +3904,18 @@ private:
 
 public:
 #ifndef _LIBCPP_CXX03_LANG
-    wbuffer_convert() : wbuffer_convert(nullptr) {}
-    explicit wbuffer_convert(streambuf* __bytebuf,
+    _LIBCPP_HIDE_FROM_ABI wbuffer_convert() : wbuffer_convert(nullptr) {}
+    explicit _LIBCPP_HIDE_FROM_ABI wbuffer_convert(streambuf* __bytebuf,
                              _Codecvt* __pcvt = new _Codecvt,
                              state_type __state = state_type());
 #else
-    _LIBCPP_EXPLICIT_SINCE_CXX14
+    _LIBCPP_EXPLICIT_SINCE_CXX14 _LIBCPP_HIDE_FROM_ABI
     wbuffer_convert(streambuf* __bytebuf = nullptr,
                     _Codecvt* __pcvt = new _Codecvt,
                     state_type __state = state_type());
 #endif
 
-    ~wbuffer_convert();
+    _LIBCPP_HIDE_FROM_ABI ~wbuffer_convert();
 
     _LIBCPP_INLINE_VISIBILITY
     streambuf* rdbuf() const {return __bufptr_;}
@@ -3931,21 +3931,21 @@ public:
     state_type state() const {return __st_;}
 
 protected:
-    virtual int_type underflow();
-    virtual int_type pbackfail(int_type __c = traits_type::eof());
-    virtual int_type overflow (int_type __c = traits_type::eof());
-    virtual basic_streambuf<char_type, traits_type>* setbuf(char_type* __s,
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual int_type underflow();
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual int_type pbackfail(int_type __c = traits_type::eof());
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual int_type overflow (int_type __c = traits_type::eof());
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual basic_streambuf<char_type, traits_type>* setbuf(char_type* __s,
                                                             streamsize __n);
-    virtual pos_type seekoff(off_type __off, ios_base::seekdir __way,
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual pos_type seekoff(off_type __off, ios_base::seekdir __way,
                              ios_base::openmode __wch = ios_base::in | ios_base::out);
-    virtual pos_type seekpos(pos_type __sp,
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual pos_type seekpos(pos_type __sp,
                              ios_base::openmode __wch = ios_base::in | ios_base::out);
-    virtual int sync();
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual int sync();
 
 private:
-    bool __read_mode();
-    void __write_mode();
-    wbuffer_convert* __close();
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL bool __read_mode();
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL void __write_mode();
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL wbuffer_convert* __close();
 };
 
 _LIBCPP_SUPPRESS_DEPRECATED_PUSH
index 75de40b..7069518 100644 (file)
@@ -605,7 +605,7 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     bool operator()(const _Key& __x, const _CP& __y) const
         {return static_cast<const _Compare&>(*this)(__x, __y.__get_value().first);}
-    void swap(__map_value_compare& __y)
+    _LIBCPP_HIDE_FROM_ABI void swap(__map_value_compare& __y)
         _NOEXCEPT_(__is_nothrow_swappable<_Compare>::value)
     {
       using _VSTD::swap;
@@ -1117,7 +1117,7 @@ public:
         {
         }
 
-    map(map&& __m, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI map(map&& __m, const allocator_type& __a);
 
     _LIBCPP_INLINE_VISIBILITY
     map& operator=(map&& __m)
@@ -1211,13 +1211,13 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     size_type max_size() const _NOEXCEPT {return __tree_.max_size();}
 
-    mapped_type& operator[](const key_type& __k);
+    _LIBCPP_HIDE_FROM_ABI mapped_type& operator[](const key_type& __k);
 #ifndef _LIBCPP_CXX03_LANG
-    mapped_type& operator[](key_type&& __k);
+    _LIBCPP_HIDE_FROM_ABI mapped_type& operator[](key_type&& __k);
 #endif
 
-          mapped_type& at(const key_type& __k);
-    const mapped_type& at(const key_type& __k) const;
+    _LIBCPP_HIDE_FROM_ABI mapped_type& at(const key_type& __k);
+    _LIBCPP_HIDE_FROM_ABI const mapped_type& at(const key_type& __k) const;
 
     _LIBCPP_INLINE_VISIBILITY
     allocator_type get_allocator() const _NOEXCEPT {return allocator_type(__tree_.__alloc());}
@@ -1556,7 +1556,7 @@ private:
     typedef unique_ptr<__node, _Dp> __node_holder;
 
 #ifdef _LIBCPP_CXX03_LANG
-    __node_holder __construct_node_with_key(const key_type& __k);
+    _LIBCPP_HIDE_FROM_ABI __node_holder __construct_node_with_key(const key_type& __k);
 #endif
 };
 
@@ -1917,7 +1917,7 @@ public:
         {
         }
 
-    multimap(multimap&& __m, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI multimap(multimap&& __m, const allocator_type& __a);
 
     _LIBCPP_INLINE_VISIBILITY
     multimap& operator=(multimap&& __m)
index ddb3f19..77f52b7 100644 (file)
@@ -227,7 +227,7 @@ void __throw_bad_optional_access() {
 
 struct nullopt_t
 {
-    struct __secret_tag { _LIBCPP_INLINE_VISIBILITY explicit __secret_tag() = default; };
+    struct __secret_tag { explicit __secret_tag() = default; };
     _LIBCPP_INLINE_VISIBILITY constexpr explicit nullopt_t(__secret_tag, __secret_tag) noexcept {}
 };
 
@@ -413,7 +413,7 @@ struct __optional_storage_base<_Tp, true>
     __raw_type* __value_;
 
     template <class _Up>
-    static constexpr bool __can_bind_reference() {
+    static _LIBCPP_HIDE_FROM_ABI constexpr bool __can_bind_reference() {
         using _RawUp = __libcpp_remove_reference_t<_Up>;
         using _UpPtr = _RawUp*;
         using _RawTp = __libcpp_remove_reference_t<_Tp>;
@@ -663,13 +663,13 @@ private:
     // LWG2756: conditionally explicit conversion from _Up
     struct _CheckOptionalArgsConstructor {
       template <class _Up>
-      static constexpr bool __enable_implicit() {
+      _LIBCPP_HIDE_FROM_ABI static constexpr bool __enable_implicit() {
           return is_constructible_v<_Tp, _Up&&> &&
                  is_convertible_v<_Up&&, _Tp>;
       }
 
       template <class _Up>
-      static constexpr bool __enable_explicit() {
+      _LIBCPP_HIDE_FROM_ABI static constexpr bool __enable_explicit() {
           return is_constructible_v<_Tp, _Up&&> &&
                  !is_convertible_v<_Up&&, _Tp>;
       }
@@ -702,17 +702,17 @@ private:
           is_assignable<_Tp&, _Opt const&&>
       >;
       template <class _Up, class _QUp = _QualUp>
-      static constexpr bool __enable_implicit() {
+      _LIBCPP_HIDE_FROM_ABI static constexpr bool __enable_implicit() {
           return is_convertible<_QUp, _Tp>::value &&
               !__check_constructible_from_opt<_Up>::value;
       }
       template <class _Up, class _QUp = _QualUp>
-      static constexpr bool __enable_explicit() {
+      _LIBCPP_HIDE_FROM_ABI static constexpr bool __enable_explicit() {
           return !is_convertible<_QUp, _Tp>::value &&
               !__check_constructible_from_opt<_Up>::value;
       }
       template <class _Up, class _QUp = _QualUp>
-      static constexpr bool __enable_assign() {
+      _LIBCPP_HIDE_FROM_ABI static constexpr bool __enable_assign() {
           // Construction and assignability of _QUp to _Tp has already been
           // checked.
           return !__check_constructible_from_opt<_Up>::value &&
@@ -830,8 +830,8 @@ public:
         return *this;
     }
 
-    constexpr optional& operator=(const optional&) = default;
-    constexpr optional& operator=(optional&&) = default;
+    _LIBCPP_HIDE_FROM_ABI constexpr optional& operator=(const optional&) = default;
+    _LIBCPP_HIDE_FROM_ABI constexpr optional& operator=(optional&&) = default;
 
     // LWG2756
     template <class _Up = value_type,
index f89b828..eae4135 100644 (file)
@@ -1005,7 +1005,7 @@ class _LIBCPP_EXCEPTION_ABI regex_error
     regex_constants::error_type __code_;
 public:
     explicit regex_error(regex_constants::error_type __ecode);
-    regex_error(const regex_error&) _NOEXCEPT = default;
+    _LIBCPP_HIDE_FROM_ABI regex_error(const regex_error&) _NOEXCEPT = default;
     ~regex_error() _NOEXCEPT override;
     _LIBCPP_INLINE_VISIBILITY
     regex_constants::error_type code() const {return __code_;}
@@ -1470,7 +1470,7 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     __end_state() {}
 
-    virtual void __exec(__state&) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state&) const;
 };
 
 template <class _CharT>
@@ -1536,7 +1536,7 @@ public:
     explicit __empty_state(__node<_CharT>* __s)
         : base(__s) {}
 
-    virtual void __exec(__state&) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state&) const;
 };
 
 template <class _CharT>
@@ -1562,7 +1562,7 @@ public:
     explicit __empty_non_own_state(__node<_CharT>* __s)
         : base(__s) {}
 
-    virtual void __exec(__state&) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state&) const;
 };
 
 template <class _CharT>
@@ -1588,7 +1588,7 @@ public:
     explicit __repeat_one_loop(__node<_CharT>* __s)
         : base(__s) {}
 
-    virtual void __exec(__state&) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state&) const;
 };
 
 template <class _CharT>
@@ -1614,7 +1614,7 @@ public:
     explicit __owns_two_states(__node<_CharT>* __s1, base* __s2)
         : base(__s1), __second_(__s2) {}
 
-    virtual ~__owns_two_states();
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual ~__owns_two_states();
 
     _LIBCPP_INLINE_VISIBILITY
     base*  second() const {return __second_;}
@@ -1657,8 +1657,8 @@ public:
           __mexp_begin_(__mexp_begin), __mexp_end_(__mexp_end),
           __greedy_(__greedy) {}
 
-    virtual void __exec(__state& __s) const;
-    virtual void __exec_split(bool __second, __state& __s) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state& __s) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec_split(bool __second, __state& __s) const;
 
 private:
     _LIBCPP_INLINE_VISIBILITY
@@ -1750,8 +1750,8 @@ public:
                          __owns_one_state<_CharT>* __s2)
         : base(__s1, __s2) {}
 
-    virtual void __exec(__state& __s) const;
-    virtual void __exec_split(bool __second, __state& __s) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state& __s) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec_split(bool __second, __state& __s) const;
 };
 
 template <class _CharT>
@@ -1788,7 +1788,7 @@ public:
     explicit __begin_marked_subexpression(unsigned __mexp, __node<_CharT>* __s)
         : base(__s), __mexp_(__mexp) {}
 
-    virtual void __exec(__state&) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state&) const;
 };
 
 template <class _CharT>
@@ -1816,7 +1816,7 @@ public:
     explicit __end_marked_subexpression(unsigned __mexp, __node<_CharT>* __s)
         : base(__s), __mexp_(__mexp) {}
 
-    virtual void __exec(__state&) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state&) const;
 };
 
 template <class _CharT>
@@ -1845,7 +1845,7 @@ public:
     explicit __back_ref(unsigned __mexp, __node<_CharT>* __s)
         : base(__s), __mexp_(__mexp) {}
 
-    virtual void __exec(__state&) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state&) const;
 };
 
 template <class _CharT>
@@ -1896,7 +1896,7 @@ public:
                               __node<_CharT>* __s)
         : base(__s), __traits_(__traits), __mexp_(__mexp) {}
 
-    virtual void __exec(__state&) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state&) const;
 };
 
 template <class _CharT, class _Traits>
@@ -1951,7 +1951,7 @@ public:
                               __node<_CharT>* __s)
         : base(__s), __traits_(__traits), __mexp_(__mexp) {}
 
-    virtual void __exec(__state&) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state&) const;
 };
 
 template <class _CharT, class _Traits>
@@ -2006,7 +2006,7 @@ public:
                              __node<_CharT>* __s)
         : base(__s), __traits_(__traits), __invert_(__invert) {}
 
-    virtual void __exec(__state&) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state&) const;
 };
 
 template <class _CharT, class _Traits>
@@ -2082,7 +2082,7 @@ public:
     __l_anchor_multiline(bool __multiline, __node<_CharT>* __s)
         : base(__s), __multiline_(__multiline) {}
 
-    virtual void __exec(__state&) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state&) const;
 };
 
 template <class _CharT>
@@ -2126,7 +2126,7 @@ public:
     __r_anchor_multiline(bool __multiline, __node<_CharT>* __s)
         : base(__s), __multiline_(__multiline) {}
 
-    virtual void __exec(__state&) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state&) const;
 };
 
 template <class _CharT>
@@ -2166,7 +2166,7 @@ public:
     __match_any(__node<_CharT>* __s)
         : base(__s) {}
 
-    virtual void __exec(__state&) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state&) const;
 };
 
 template <class _CharT>
@@ -2228,7 +2228,7 @@ public:
     __match_char(_CharT __c, __node<_CharT>* __s)
         : base(__s), __c_(__c) {}
 
-    virtual void __exec(__state&) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state&) const;
 };
 
 template <class _CharT>
@@ -2268,7 +2268,7 @@ public:
     __match_char_icase(const _Traits& __traits, _CharT __c, __node<_CharT>* __s)
         : base(__s), __traits_(__traits), __c_(__traits.translate_nocase(__c)) {}
 
-    virtual void __exec(__state&) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state&) const;
 };
 
 template <class _CharT, class _Traits>
@@ -2309,7 +2309,7 @@ public:
     __match_char_collate(const _Traits& __traits, _CharT __c, __node<_CharT>* __s)
         : base(__s), __traits_(__traits), __c_(__traits.translate(__c)) {}
 
-    virtual void __exec(__state&) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state&) const;
 };
 
 template <class _CharT, class _Traits>
@@ -2364,7 +2364,7 @@ public:
           __negate_(__negate), __icase_(__icase), __collate_(__collate),
           __might_have_digraph_(__traits_.getloc().name() != "C") {}
 
-    virtual void __exec(__state&) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state&) const;
 
     _LIBCPP_INLINE_VISIBILITY
     bool __negated() const {return __negate_;}
@@ -3156,7 +3156,7 @@ public:
     __lookahead(const basic_regex<_CharT, _Traits>& __exp, bool __invert, __node<_CharT>* __s, unsigned __mexp)
         : base(__s), __exp_(__exp), __mexp_(__mexp), __invert_(__invert) {}
 
-    virtual void __exec(__state&) const;
+    _LIBCPP_HIDE_FROM_ABI_VIRTUAL virtual void __exec(__state&) const;
 };
 
 template <class _CharT, class _Traits>
index f6160b5..bb61a7c 100644 (file)
@@ -531,7 +531,7 @@ public:
                          __p, _VSTD::forward<_Args>(__args)...);}
 
     template <class _T1, class _T2, class... _Args1, class... _Args2>
-    void construct(pair<_T1, _T2>* __p, piecewise_construct_t,
+    _LIBCPP_HIDE_FROM_ABI void construct(pair<_T1, _T2>* __p, piecewise_construct_t,
                        tuple<_Args1...> __x, tuple<_Args2...> __y)
     {
         typedef __outermost<outer_allocator_type> _OM;
@@ -555,25 +555,25 @@ public:
     }
 
     template <class _T1, class _T2>
-    void construct(pair<_T1, _T2>* __p)
+    _LIBCPP_HIDE_FROM_ABI void construct(pair<_T1, _T2>* __p)
     { construct(__p, piecewise_construct, tuple<>{}, tuple<>{}); }
 
     template <class _T1, class _T2, class _Up, class _Vp>
-    void construct(pair<_T1, _T2>* __p, _Up&& __x, _Vp&& __y) {
+    _LIBCPP_HIDE_FROM_ABI void construct(pair<_T1, _T2>* __p, _Up&& __x, _Vp&& __y) {
         construct(__p, piecewise_construct,
                   _VSTD::forward_as_tuple(_VSTD::forward<_Up>(__x)),
                   _VSTD::forward_as_tuple(_VSTD::forward<_Vp>(__y)));
     }
 
     template <class _T1, class _T2, class _Up, class _Vp>
-    void construct(pair<_T1, _T2>* __p, const pair<_Up, _Vp>& __x) {
+    _LIBCPP_HIDE_FROM_ABI void construct(pair<_T1, _T2>* __p, const pair<_Up, _Vp>& __x) {
         construct(__p, piecewise_construct,
                   _VSTD::forward_as_tuple(__x.first),
                   _VSTD::forward_as_tuple(__x.second));
     }
 
     template <class _T1, class _T2, class _Up, class _Vp>
-    void construct(pair<_T1, _T2>* __p, pair<_Up, _Vp>&& __x) {
+    _LIBCPP_HIDE_FROM_ABI void construct(pair<_T1, _T2>* __p, pair<_Up, _Vp>&& __x) {
         construct(__p, piecewise_construct,
                   _VSTD::forward_as_tuple(_VSTD::forward<_Up>(__x.first)),
                   _VSTD::forward_as_tuple(_VSTD::forward<_Vp>(__x.second)));
index 05bffe6..b68806d 100644 (file)
@@ -633,7 +633,7 @@ public:
         }
 
 #ifndef _LIBCPP_CXX03_LANG
-    set(set&& __s, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI set(set&& __s, const allocator_type& __a);
 
     _LIBCPP_INLINE_VISIBILITY
     set(initializer_list<value_type> __il, const value_compare& __comp = value_compare())
@@ -1158,7 +1158,7 @@ public:
         _NOEXCEPT_(is_nothrow_move_constructible<__base>::value)
         : __tree_(_VSTD::move(__s.__tree_)) {}
 
-    multiset(multiset&& __s, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI multiset(multiset&& __s, const allocator_type& __a);
 #endif // _LIBCPP_CXX03_LANG
     _LIBCPP_INLINE_VISIBILITY
     explicit multiset(const allocator_type& __a)
index db35514..f84a7d9 100644 (file)
@@ -406,13 +406,13 @@ public:
         return *this;
     }
 
-    void lock();
-    bool try_lock();
+    _LIBCPP_HIDE_FROM_ABI void lock();
+    _LIBCPP_HIDE_FROM_ABI bool try_lock();
     template <class Rep, class Period>
-        bool try_lock_for(const chrono::duration<Rep, Period>& __rel_time);
+    _LIBCPP_HIDE_FROM_ABI bool try_lock_for(const chrono::duration<Rep, Period>& __rel_time);
     template <class Clock, class Duration>
-        bool try_lock_until(const chrono::time_point<Clock, Duration>& __abs_time);
-    void unlock();
+    _LIBCPP_HIDE_FROM_ABI bool try_lock_until(const chrono::time_point<Clock, Duration>& __abs_time);
+    _LIBCPP_HIDE_FROM_ABI void unlock();
 
     // Setters
     _LIBCPP_INLINE_VISIBILITY
index 8e2f985..54be719 100644 (file)
@@ -65,7 +65,7 @@ public:
     __libcpp_refstring& operator=(const __libcpp_refstring& __s) _NOEXCEPT;
     ~__libcpp_refstring();
 
-    const char* c_str() const _NOEXCEPT {return __imp_;}
+    _LIBCPP_HIDE_FROM_ABI const char* c_str() const _NOEXCEPT {return __imp_;}
 };
 #endif // !_LIBCPP_ABI_VCRUNTIME
 
@@ -128,7 +128,7 @@ public:
     _LIBCPP_INLINE_VISIBILITY explicit domain_error(const char* __s)   : logic_error(__s) {}
 
 #ifndef _LIBCPP_ABI_VCRUNTIME
-    domain_error(const domain_error&) _NOEXCEPT = default;
+    _LIBCPP_HIDE_FROM_ABI domain_error(const domain_error&) _NOEXCEPT = default;
     ~domain_error() _NOEXCEPT override;
 #endif
 };
@@ -141,7 +141,7 @@ public:
     _LIBCPP_INLINE_VISIBILITY explicit invalid_argument(const char* __s)   : logic_error(__s) {}
 
 #ifndef _LIBCPP_ABI_VCRUNTIME
-    invalid_argument(const invalid_argument&) _NOEXCEPT = default;
+    _LIBCPP_HIDE_FROM_ABI invalid_argument(const invalid_argument&) _NOEXCEPT = default;
     ~invalid_argument() _NOEXCEPT override;
 #endif
 };
@@ -153,7 +153,7 @@ public:
     _LIBCPP_INLINE_VISIBILITY explicit length_error(const string& __s) : logic_error(__s) {}
     _LIBCPP_INLINE_VISIBILITY explicit length_error(const char* __s)   : logic_error(__s) {}
 #ifndef _LIBCPP_ABI_VCRUNTIME
-    length_error(const length_error&) _NOEXCEPT = default;
+    _LIBCPP_HIDE_FROM_ABI length_error(const length_error&) _NOEXCEPT = default;
     ~length_error() _NOEXCEPT override;
 #endif
 };
@@ -166,7 +166,7 @@ public:
     _LIBCPP_INLINE_VISIBILITY explicit out_of_range(const char* __s)   : logic_error(__s) {}
 
 #ifndef _LIBCPP_ABI_VCRUNTIME
-    out_of_range(const out_of_range&) _NOEXCEPT = default;
+    _LIBCPP_HIDE_FROM_ABI out_of_range(const out_of_range&) _NOEXCEPT = default;
     ~out_of_range() _NOEXCEPT override;
 #endif
 };
@@ -179,7 +179,7 @@ public:
     _LIBCPP_INLINE_VISIBILITY explicit range_error(const char* __s)   : runtime_error(__s) {}
 
 #ifndef _LIBCPP_ABI_VCRUNTIME
-    range_error(const range_error&) _NOEXCEPT = default;
+    _LIBCPP_HIDE_FROM_ABI range_error(const range_error&) _NOEXCEPT = default;
     ~range_error() _NOEXCEPT override;
 #endif
 };
@@ -192,7 +192,7 @@ public:
     _LIBCPP_INLINE_VISIBILITY explicit overflow_error(const char* __s)   : runtime_error(__s) {}
 
 #ifndef _LIBCPP_ABI_VCRUNTIME
-    overflow_error(const overflow_error&) _NOEXCEPT = default;
+    _LIBCPP_HIDE_FROM_ABI overflow_error(const overflow_error&) _NOEXCEPT = default;
     ~overflow_error() _NOEXCEPT override;
 #endif
 };
@@ -205,7 +205,7 @@ public:
     _LIBCPP_INLINE_VISIBILITY explicit underflow_error(const char* __s)   : runtime_error(__s) {}
 
 #ifndef _LIBCPP_ABI_VCRUNTIME
-    underflow_error(const underflow_error&) _NOEXCEPT = default;
+    _LIBCPP_HIDE_FROM_ABI underflow_error(const underflow_error&) _NOEXCEPT = default;
     ~underflow_error() _NOEXCEPT override;
 #endif
 };
index 9382473..d0688fc 100644 (file)
@@ -146,7 +146,7 @@ class _LIBCPP_TYPE_VIS strstreambuf
 {
 public:
 #ifndef _LIBCPP_CXX03_LANG
-    strstreambuf() : strstreambuf(0) {}
+    _LIBCPP_HIDE_FROM_ABI strstreambuf() : strstreambuf(0) {}
     explicit strstreambuf(streamsize __alsize);
 #else
     explicit strstreambuf(streamsize __alsize = 0);
index e071476..7b3b89c 100644 (file)
@@ -376,7 +376,7 @@ struct __thread_invoke_pair {
     // This type is used to pass memory for thread local storage and a functor
     // to a newly created thread because std::pair doesn't work with
     // std::unique_ptr in C++03.
-    __thread_invoke_pair(_Fp& __f) : __tsp_(new __thread_struct), __fn_(__f) {}
+    _LIBCPP_HIDE_FROM_ABI __thread_invoke_pair(_Fp& __f) : __tsp_(new __thread_struct), __fn_(__f) {}
     unique_ptr<__thread_struct> __tsp_;
     _Fp __fn_;
 };
index abfd441..9ef197f 100644 (file)
@@ -295,7 +295,7 @@ class __tuple_leaf
     _Hp __value_;
 
     template <class _Tp>
-    static constexpr bool __can_bind_reference() {
+    static _LIBCPP_HIDE_FROM_ABI constexpr bool __can_bind_reference() {
 #if __has_keyword(__reference_binds_to_temporary)
       return !__reference_binds_to_temporary(_Hp, _Tp);
 #else
@@ -367,8 +367,8 @@ public:
         {static_assert(!is_reference<_Hp>::value,
            "Attempted to uses-allocator construct a reference element in a tuple");}
 
-    __tuple_leaf(const __tuple_leaf& __t) = default;
-    __tuple_leaf(__tuple_leaf&& __t) = default;
+    _LIBCPP_HIDE_FROM_ABI __tuple_leaf(const __tuple_leaf& __t) = default;
+    _LIBCPP_HIDE_FROM_ABI __tuple_leaf(__tuple_leaf&& __t) = default;
 
     _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_SINCE_CXX14
     int swap(__tuple_leaf& __t) _NOEXCEPT_(__is_nothrow_swappable<__tuple_leaf>::value)
@@ -1308,8 +1308,7 @@ template <>
 class _LIBCPP_TEMPLATE_VIS tuple<>
 {
 public:
-    _LIBCPP_INLINE_VISIBILITY constexpr
-        tuple() _NOEXCEPT = default;
+    constexpr tuple() _NOEXCEPT = default;
     template <class _Alloc>
     _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_SINCE_CXX20
         tuple(allocator_arg_t, const _Alloc&) _NOEXCEPT {}
index 4691765..3392cb4 100644 (file)
@@ -359,7 +359,7 @@ class _LIBCPP_EXCEPTION_ABI bad_cast
 {
  public:
   bad_cast() _NOEXCEPT;
-  bad_cast(const bad_cast&) _NOEXCEPT = default;
+  _LIBCPP_HIDE_FROM_ABI bad_cast(const bad_cast&) _NOEXCEPT = default;
   ~bad_cast() _NOEXCEPT override;
   const char* what() const _NOEXCEPT override;
 };
index 238aa44..ce3d61f 100644 (file)
@@ -1091,35 +1091,35 @@ public:
     {
         _VSTD::__debug_db_insert_c(this);
     }
-    explicit unordered_map(size_type __n, const hasher& __hf = hasher(),
+    explicit _LIBCPP_HIDE_FROM_ABI unordered_map(size_type __n, const hasher& __hf = hasher(),
                            const key_equal& __eql = key_equal());
-    unordered_map(size_type __n, const hasher& __hf,
+    _LIBCPP_HIDE_FROM_ABI unordered_map(size_type __n, const hasher& __hf,
                   const key_equal& __eql,
                   const allocator_type& __a);
     template <class _InputIterator>
-        unordered_map(_InputIterator __first, _InputIterator __last);
+    _LIBCPP_HIDE_FROM_ABI unordered_map(_InputIterator __first, _InputIterator __last);
     template <class _InputIterator>
-        unordered_map(_InputIterator __first, _InputIterator __last,
+    _LIBCPP_HIDE_FROM_ABI unordered_map(_InputIterator __first, _InputIterator __last,
                       size_type __n, const hasher& __hf = hasher(),
                       const key_equal& __eql = key_equal());
     template <class _InputIterator>
-        unordered_map(_InputIterator __first, _InputIterator __last,
+    _LIBCPP_HIDE_FROM_ABI unordered_map(_InputIterator __first, _InputIterator __last,
                       size_type __n, const hasher& __hf,
                       const key_equal& __eql,
                       const allocator_type& __a);
     _LIBCPP_INLINE_VISIBILITY
     explicit unordered_map(const allocator_type& __a);
-    unordered_map(const unordered_map& __u);
-    unordered_map(const unordered_map& __u, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI unordered_map(const unordered_map& __u);
+    _LIBCPP_HIDE_FROM_ABI unordered_map(const unordered_map& __u, const allocator_type& __a);
 #ifndef _LIBCPP_CXX03_LANG
     _LIBCPP_INLINE_VISIBILITY
     unordered_map(unordered_map&& __u)
         _NOEXCEPT_(is_nothrow_move_constructible<__table>::value);
-    unordered_map(unordered_map&& __u, const allocator_type& __a);
-    unordered_map(initializer_list<value_type> __il);
-    unordered_map(initializer_list<value_type> __il, size_type __n,
+    _LIBCPP_HIDE_FROM_ABI unordered_map(unordered_map&& __u, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI unordered_map(initializer_list<value_type> __il);
+    _LIBCPP_HIDE_FROM_ABI unordered_map(initializer_list<value_type> __il, size_type __n,
                   const hasher& __hf = hasher(), const key_equal& __eql = key_equal());
-    unordered_map(initializer_list<value_type> __il, size_type __n,
+    _LIBCPP_HIDE_FROM_ABI unordered_map(initializer_list<value_type> __il, size_type __n,
                   const hasher& __hf, const key_equal& __eql,
                   const allocator_type& __a);
 #endif // _LIBCPP_CXX03_LANG
@@ -1205,7 +1205,7 @@ public:
     pair<iterator, bool> insert(const value_type& __x)
         {return __table_.__insert_unique(__x);}
 
-    iterator insert(const_iterator __p, const value_type& __x) {
+    _LIBCPP_HIDE_FROM_ABI iterator insert(const_iterator __p, const value_type& __x) {
         _LIBCPP_DEBUG_ASSERT(__get_const_db()->__find_c_from_i(_VSTD::addressof(__p)) == this,
                              "unordered_map::insert(const_iterator, const value_type&) called with an iterator not "
                              "referring to this unordered_map");
@@ -1226,7 +1226,7 @@ public:
     pair<iterator, bool> insert(value_type&& __x)
         {return __table_.__insert_unique(_VSTD::move(__x));}
 
-    iterator insert(const_iterator __p, value_type&& __x) {
+    _LIBCPP_HIDE_FROM_ABI iterator insert(const_iterator __p, value_type&& __x) {
         _LIBCPP_DEBUG_ASSERT(__get_const_db()->__find_c_from_i(_VSTD::addressof(__p)) == this,
                              "unordered_map::insert(const_iterator, const value_type&) called with an iterator not"
                              " referring to this unordered_map");
@@ -1486,13 +1486,13 @@ public:
         {return __table_.__equal_range_unique(__k);}
 #endif // _LIBCPP_STD_VER >= 20
 
-    mapped_type& operator[](const key_type& __k);
+    _LIBCPP_HIDE_FROM_ABI mapped_type& operator[](const key_type& __k);
 #ifndef _LIBCPP_CXX03_LANG
-    mapped_type& operator[](key_type&& __k);
+    _LIBCPP_HIDE_FROM_ABI mapped_type& operator[](key_type&& __k);
 #endif
 
-    mapped_type&       at(const key_type& __k);
-    const mapped_type& at(const key_type& __k) const;
+    _LIBCPP_HIDE_FROM_ABI mapped_type&       at(const key_type& __k);
+    _LIBCPP_HIDE_FROM_ABI const mapped_type& at(const key_type& __k) const;
 
     _LIBCPP_INLINE_VISIBILITY
     size_type bucket_count() const _NOEXCEPT {return __table_.bucket_count();}
@@ -1531,13 +1531,13 @@ public:
 
 #ifdef _LIBCPP_ENABLE_DEBUG_MODE
 
-    bool __dereferenceable(const const_iterator* __i) const
+    _LIBCPP_HIDE_FROM_ABI bool __dereferenceable(const const_iterator* __i) const
         {return __table_.__dereferenceable(_VSTD::addressof(__i->__i_));}
-    bool __decrementable(const const_iterator* __i) const
+    _LIBCPP_HIDE_FROM_ABI bool __decrementable(const const_iterator* __i) const
         {return __table_.__decrementable(_VSTD::addressof(__i->__i_));}
-    bool __addable(const const_iterator* __i, ptrdiff_t __n) const
+    _LIBCPP_HIDE_FROM_ABI bool __addable(const const_iterator* __i, ptrdiff_t __n) const
         {return __table_.__addable(_VSTD::addressof(__i->__i_), __n);}
-    bool __subscriptable(const const_iterator* __i, ptrdiff_t __n) const
+    _LIBCPP_HIDE_FROM_ABI bool __subscriptable(const const_iterator* __i, ptrdiff_t __n) const
         {return __table_.__addable(_VSTD::addressof(__i->__i_), __n);}
 
 #endif // _LIBCPP_ENABLE_DEBUG_MODE
@@ -1545,7 +1545,7 @@ public:
 private:
 
 #ifdef _LIBCPP_CXX03_LANG
-    __node_holder __construct_node_with_key(const key_type& __k);
+    _LIBCPP_HIDE_FROM_ABI __node_holder __construct_node_with_key(const key_type& __k);
 #endif
 };
 
@@ -1982,36 +1982,36 @@ private:
     {
         _VSTD::__debug_db_insert_c(this);
     }
-    explicit unordered_multimap(size_type __n, const hasher& __hf = hasher(),
+    explicit _LIBCPP_HIDE_FROM_ABI unordered_multimap(size_type __n, const hasher& __hf = hasher(),
                                 const key_equal& __eql = key_equal());
-    unordered_multimap(size_type __n, const hasher& __hf,
+    _LIBCPP_HIDE_FROM_ABI unordered_multimap(size_type __n, const hasher& __hf,
                                 const key_equal& __eql,
                                 const allocator_type& __a);
     template <class _InputIterator>
-        unordered_multimap(_InputIterator __first, _InputIterator __last);
+    _LIBCPP_HIDE_FROM_ABI unordered_multimap(_InputIterator __first, _InputIterator __last);
     template <class _InputIterator>
-        unordered_multimap(_InputIterator __first, _InputIterator __last,
+    _LIBCPP_HIDE_FROM_ABI unordered_multimap(_InputIterator __first, _InputIterator __last,
                       size_type __n, const hasher& __hf = hasher(),
                       const key_equal& __eql = key_equal());
     template <class _InputIterator>
-        unordered_multimap(_InputIterator __first, _InputIterator __last,
+    _LIBCPP_HIDE_FROM_ABI unordered_multimap(_InputIterator __first, _InputIterator __last,
                       size_type __n, const hasher& __hf,
                       const key_equal& __eql,
                       const allocator_type& __a);
     _LIBCPP_INLINE_VISIBILITY
     explicit unordered_multimap(const allocator_type& __a);
-    unordered_multimap(const unordered_multimap& __u);
-    unordered_multimap(const unordered_multimap& __u, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI unordered_multimap(const unordered_multimap& __u);
+    _LIBCPP_HIDE_FROM_ABI unordered_multimap(const unordered_multimap& __u, const allocator_type& __a);
 #ifndef _LIBCPP_CXX03_LANG
     _LIBCPP_INLINE_VISIBILITY
     unordered_multimap(unordered_multimap&& __u)
         _NOEXCEPT_(is_nothrow_move_constructible<__table>::value);
-    unordered_multimap(unordered_multimap&& __u, const allocator_type& __a);
-    unordered_multimap(initializer_list<value_type> __il);
-    unordered_multimap(initializer_list<value_type> __il, size_type __n,
+    _LIBCPP_HIDE_FROM_ABI unordered_multimap(unordered_multimap&& __u, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI unordered_multimap(initializer_list<value_type> __il);
+    _LIBCPP_HIDE_FROM_ABI unordered_multimap(initializer_list<value_type> __il, size_type __n,
                        const hasher& __hf = hasher(),
                        const key_equal& __eql = key_equal());
-    unordered_multimap(initializer_list<value_type> __il, size_type __n,
+    _LIBCPP_HIDE_FROM_ABI unordered_multimap(initializer_list<value_type> __il, size_type __n,
                        const hasher& __hf, const key_equal& __eql,
                        const allocator_type& __a);
 #endif // _LIBCPP_CXX03_LANG
@@ -2128,12 +2128,12 @@ private:
         {return __table_.__insert_multi(__p.__i_, _VSTD::forward<_Pp>(__x));}
 
     template <class... _Args>
-    iterator emplace(_Args&&... __args) {
+    _LIBCPP_HIDE_FROM_ABI iterator emplace(_Args&&... __args) {
         return __table_.__emplace_multi(_VSTD::forward<_Args>(__args)...);
     }
 
     template <class... _Args>
-    iterator emplace_hint(const_iterator __p, _Args&&... __args) {
+    _LIBCPP_HIDE_FROM_ABI iterator emplace_hint(const_iterator __p, _Args&&... __args) {
         return __table_.__emplace_hint_multi(__p.__i_, _VSTD::forward<_Args>(__args)...);
     }
 #endif // _LIBCPP_CXX03_LANG
@@ -2311,13 +2311,13 @@ private:
 
 #ifdef _LIBCPP_ENABLE_DEBUG_MODE
 
-    bool __dereferenceable(const const_iterator* __i) const
+    _LIBCPP_HIDE_FROM_ABI bool __dereferenceable(const const_iterator* __i) const
         {return __table_.__dereferenceable(_VSTD::addressof(__i->__i_));}
-    bool __decrementable(const const_iterator* __i) const
+    _LIBCPP_HIDE_FROM_ABI bool __decrementable(const const_iterator* __i) const
         {return __table_.__decrementable(_VSTD::addressof(__i->__i_));}
-    bool __addable(const const_iterator* __i, ptrdiff_t __n) const
+    _LIBCPP_HIDE_FROM_ABI bool __addable(const const_iterator* __i, ptrdiff_t __n) const
         {return __table_.__addable(_VSTD::addressof(__i->__i_), __n);}
-    bool __subscriptable(const const_iterator* __i, ptrdiff_t __n) const
+    _LIBCPP_HIDE_FROM_ABI bool __subscriptable(const const_iterator* __i, ptrdiff_t __n) const
         {return __table_.__addable(_VSTD::addressof(__i->__i_), __n);}
 
 #endif // _LIBCPP_ENABLE_DEBUG_MODE
index a6afb74..f8d1f05 100644 (file)
@@ -551,7 +551,7 @@ public:
     {
         _VSTD::__debug_db_insert_c(this);
     }
-    explicit unordered_set(size_type __n, const hasher& __hf = hasher(),
+    explicit _LIBCPP_HIDE_FROM_ABI unordered_set(size_type __n, const hasher& __hf = hasher(),
                            const key_equal& __eql = key_equal());
 #if _LIBCPP_STD_VER >= 14
     inline _LIBCPP_INLINE_VISIBILITY
@@ -561,16 +561,16 @@ public:
     unordered_set(size_type __n, const hasher& __hf, const allocator_type& __a)
         : unordered_set(__n, __hf, key_equal(), __a) {}
 #endif
-    unordered_set(size_type __n, const hasher& __hf, const key_equal& __eql,
+    _LIBCPP_HIDE_FROM_ABI unordered_set(size_type __n, const hasher& __hf, const key_equal& __eql,
                   const allocator_type& __a);
     template <class _InputIterator>
-        unordered_set(_InputIterator __first, _InputIterator __last);
+    _LIBCPP_HIDE_FROM_ABI unordered_set(_InputIterator __first, _InputIterator __last);
     template <class _InputIterator>
-        unordered_set(_InputIterator __first, _InputIterator __last,
+    _LIBCPP_HIDE_FROM_ABI unordered_set(_InputIterator __first, _InputIterator __last,
                       size_type __n, const hasher& __hf = hasher(),
                       const key_equal& __eql = key_equal());
     template <class _InputIterator>
-        unordered_set(_InputIterator __first, _InputIterator __last,
+    _LIBCPP_HIDE_FROM_ABI unordered_set(_InputIterator __first, _InputIterator __last,
                       size_type __n, const hasher& __hf, const key_equal& __eql,
                       const allocator_type& __a);
 #if _LIBCPP_STD_VER >= 14
@@ -580,24 +580,24 @@ public:
                     size_type __n, const allocator_type& __a)
             : unordered_set(__first, __last, __n, hasher(), key_equal(), __a) {}
     template <class _InputIterator>
-        unordered_set(_InputIterator __first, _InputIterator __last,
+    _LIBCPP_HIDE_FROM_ABI unordered_set(_InputIterator __first, _InputIterator __last,
                       size_type __n, const hasher& __hf, const allocator_type& __a)
             : unordered_set(__first, __last, __n, __hf, key_equal(), __a) {}
 #endif
     _LIBCPP_INLINE_VISIBILITY
     explicit unordered_set(const allocator_type& __a);
-    unordered_set(const unordered_set& __u);
-    unordered_set(const unordered_set& __u, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI unordered_set(const unordered_set& __u);
+    _LIBCPP_HIDE_FROM_ABI unordered_set(const unordered_set& __u, const allocator_type& __a);
 #ifndef _LIBCPP_CXX03_LANG
     _LIBCPP_INLINE_VISIBILITY
     unordered_set(unordered_set&& __u)
         _NOEXCEPT_(is_nothrow_move_constructible<__table>::value);
-    unordered_set(unordered_set&& __u, const allocator_type& __a);
-    unordered_set(initializer_list<value_type> __il);
-    unordered_set(initializer_list<value_type> __il, size_type __n,
+    _LIBCPP_HIDE_FROM_ABI unordered_set(unordered_set&& __u, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI unordered_set(initializer_list<value_type> __il);
+    _LIBCPP_HIDE_FROM_ABI unordered_set(initializer_list<value_type> __il, size_type __n,
                   const hasher& __hf = hasher(),
                   const key_equal& __eql = key_equal());
-    unordered_set(initializer_list<value_type> __il, size_type __n,
+    _LIBCPP_HIDE_FROM_ABI unordered_set(initializer_list<value_type> __il, size_type __n,
                   const hasher& __hf, const key_equal& __eql,
                   const allocator_type& __a);
 #if _LIBCPP_STD_VER >= 14
@@ -866,13 +866,13 @@ public:
 
 #ifdef _LIBCPP_ENABLE_DEBUG_MODE
 
-    bool __dereferenceable(const const_iterator* __i) const
+    _LIBCPP_HIDE_FROM_ABI bool __dereferenceable(const const_iterator* __i) const
         {return __table_.__dereferenceable(__i);}
-    bool __decrementable(const const_iterator* __i) const
+    _LIBCPP_HIDE_FROM_ABI bool __decrementable(const const_iterator* __i) const
         {return __table_.__decrementable(__i);}
-    bool __addable(const const_iterator* __i, ptrdiff_t __n) const
+    _LIBCPP_HIDE_FROM_ABI bool __addable(const const_iterator* __i, ptrdiff_t __n) const
         {return __table_.__addable(__i, __n);}
-    bool __subscriptable(const const_iterator* __i, ptrdiff_t __n) const
+    _LIBCPP_HIDE_FROM_ABI bool __subscriptable(const const_iterator* __i, ptrdiff_t __n) const
         {return __table_.__addable(__i, __n);}
 
 #endif // _LIBCPP_ENABLE_DEBUG_MODE
@@ -1206,9 +1206,9 @@ public:
     {
         _VSTD::__debug_db_insert_c(this);
     }
-    explicit unordered_multiset(size_type __n, const hasher& __hf = hasher(),
+    explicit _LIBCPP_HIDE_FROM_ABI unordered_multiset(size_type __n, const hasher& __hf = hasher(),
                                 const key_equal& __eql = key_equal());
-    unordered_multiset(size_type __n, const hasher& __hf,
+    _LIBCPP_HIDE_FROM_ABI unordered_multiset(size_type __n, const hasher& __hf,
                        const key_equal& __eql, const allocator_type& __a);
 #if _LIBCPP_STD_VER >= 14
     inline _LIBCPP_INLINE_VISIBILITY
@@ -1219,13 +1219,13 @@ public:
         : unordered_multiset(__n, __hf, key_equal(), __a) {}
 #endif
     template <class _InputIterator>
-        unordered_multiset(_InputIterator __first, _InputIterator __last);
+    _LIBCPP_HIDE_FROM_ABI unordered_multiset(_InputIterator __first, _InputIterator __last);
     template <class _InputIterator>
-        unordered_multiset(_InputIterator __first, _InputIterator __last,
+    _LIBCPP_HIDE_FROM_ABI unordered_multiset(_InputIterator __first, _InputIterator __last,
                       size_type __n, const hasher& __hf = hasher(),
                       const key_equal& __eql = key_equal());
     template <class _InputIterator>
-        unordered_multiset(_InputIterator __first, _InputIterator __last,
+    _LIBCPP_HIDE_FROM_ABI unordered_multiset(_InputIterator __first, _InputIterator __last,
                       size_type __n , const hasher& __hf,
                       const key_equal& __eql, const allocator_type& __a);
 #if _LIBCPP_STD_VER >= 14
@@ -1242,18 +1242,18 @@ public:
 #endif
     _LIBCPP_INLINE_VISIBILITY
     explicit unordered_multiset(const allocator_type& __a);
-    unordered_multiset(const unordered_multiset& __u);
-    unordered_multiset(const unordered_multiset& __u, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI unordered_multiset(const unordered_multiset& __u);
+    _LIBCPP_HIDE_FROM_ABI unordered_multiset(const unordered_multiset& __u, const allocator_type& __a);
 #ifndef _LIBCPP_CXX03_LANG
     _LIBCPP_INLINE_VISIBILITY
     unordered_multiset(unordered_multiset&& __u)
         _NOEXCEPT_(is_nothrow_move_constructible<__table>::value);
-    unordered_multiset(unordered_multiset&& __u, const allocator_type& __a);
-    unordered_multiset(initializer_list<value_type> __il);
-    unordered_multiset(initializer_list<value_type> __il, size_type __n,
+    _LIBCPP_HIDE_FROM_ABI unordered_multiset(unordered_multiset&& __u, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI unordered_multiset(initializer_list<value_type> __il);
+    _LIBCPP_HIDE_FROM_ABI unordered_multiset(initializer_list<value_type> __il, size_type __n,
                        const hasher& __hf = hasher(),
                        const key_equal& __eql = key_equal());
-    unordered_multiset(initializer_list<value_type> __il, size_type __n,
+    _LIBCPP_HIDE_FROM_ABI unordered_multiset(initializer_list<value_type> __il, size_type __n,
                        const hasher& __hf, const key_equal& __eql,
                        const allocator_type& __a);
 #if _LIBCPP_STD_VER >= 14
@@ -1280,7 +1280,7 @@ public:
     _LIBCPP_INLINE_VISIBILITY
     unordered_multiset& operator=(unordered_multiset&& __u)
         _NOEXCEPT_(is_nothrow_move_assignable<__table>::value);
-    unordered_multiset& operator=(initializer_list<value_type> __il);
+    _LIBCPP_HIDE_FROM_ABI unordered_multiset& operator=(initializer_list<value_type> __il);
 #endif // _LIBCPP_CXX03_LANG
 
     _LIBCPP_INLINE_VISIBILITY
@@ -1504,13 +1504,13 @@ public:
 
 #ifdef _LIBCPP_ENABLE_DEBUG_MODE
 
-    bool __dereferenceable(const const_iterator* __i) const
+    _LIBCPP_HIDE_FROM_ABI bool __dereferenceable(const const_iterator* __i) const
         {return __table_.__dereferenceable(__i);}
-    bool __decrementable(const const_iterator* __i) const
+    _LIBCPP_HIDE_FROM_ABI bool __decrementable(const const_iterator* __i) const
         {return __table_.__decrementable(__i);}
-    bool __addable(const const_iterator* __i, ptrdiff_t __n) const
+    _LIBCPP_HIDE_FROM_ABI bool __addable(const const_iterator* __i, ptrdiff_t __n) const
         {return __table_.__addable(__i, __n);}
-    bool __subscriptable(const const_iterator* __i, ptrdiff_t __n) const
+    _LIBCPP_HIDE_FROM_ABI bool __subscriptable(const const_iterator* __i, ptrdiff_t __n) const
         {return __table_.__addable(__i, __n);}
 
 #endif // _LIBCPP_ENABLE_DEBUG_MODE
index 425fead..7dcbe1f 100644 (file)
@@ -550,7 +550,7 @@ private:
   }
 
   template <class _Fp, class... _Fs>
-  static constexpr void __std_visit_visitor_return_type_check() {
+  static _LIBCPP_HIDE_FROM_ABI constexpr void __std_visit_visitor_return_type_check() {
     static_assert(
         __all<is_same_v<_Fp, _Fs>...>::value,
         "`std::visit` requires the visitor to have a single return type.");
@@ -676,7 +676,7 @@ struct __variant {
 
 private:
   template <class _Visitor, class... _Values>
-  static constexpr void __std_visit_exhaustive_visitor_check() {
+  static _LIBCPP_HIDE_FROM_ABI constexpr void __std_visit_exhaustive_visitor_check() {
     static_assert(is_invocable_v<_Visitor, _Values...>,
                   "`std::visit` requires the visitor to be exhaustive.");
   }
@@ -1037,10 +1037,10 @@ protected:
       __a.__value = _VSTD::forward<_Arg>(__arg);
     } else {
       struct {
-        void operator()(true_type) const {
+        _LIBCPP_HIDE_FROM_ABI void operator()(true_type) const {
           __this->__emplace<_Ip>(_VSTD::forward<_Arg>(__arg));
         }
-        void operator()(false_type) const {
+        _LIBCPP_HIDE_FROM_ABI void operator()(false_type) const {
           __this->__emplace<_Ip>(_Tp(_VSTD::forward<_Arg>(__arg)));
         }
         __assignment* __this;
@@ -1158,10 +1158,10 @@ class _LIBCPP_TEMPLATE_VIS __impl
 
 public:
   using __base_type::__base_type; // get in_place_index_t constructor & friends
-  __impl(__impl const&) = default;
-  __impl(__impl&&) = default;
-  __impl& operator=(__impl const&) = default;
-  __impl& operator=(__impl&&) = default;
+  _LIBCPP_HIDE_FROM_ABI __impl(__impl const&) = default;
+  _LIBCPP_HIDE_FROM_ABI __impl(__impl&&) = default;
+  _LIBCPP_HIDE_FROM_ABI __impl& operator=(__impl const&) = default;
+  _LIBCPP_HIDE_FROM_ABI __impl& operator=(__impl&&) = default;
 
   template <size_t _Ip, class _Arg>
   _LIBCPP_HIDE_FROM_ABI
@@ -1326,8 +1326,8 @@ public:
   constexpr variant() noexcept(is_nothrow_default_constructible_v<__first_type>)
       : __impl_(in_place_index<0>) {}
 
-  constexpr variant(const variant&) = default;
-  constexpr variant(variant&&) = default;
+  _LIBCPP_HIDE_FROM_ABI constexpr variant(const variant&) = default;
+  _LIBCPP_HIDE_FROM_ABI constexpr variant(variant&&) = default;
 
   template <
       class _Arg,
@@ -1396,10 +1396,10 @@ public:
       is_nothrow_constructible_v<_Tp, initializer_list< _Up>&, _Args...>)
       : __impl_(in_place_index<_Ip>, __il, _VSTD::forward<_Args>(__args)...) {}
 
-  ~variant() = default;
+  _LIBCPP_HIDE_FROM_ABI ~variant() = default;
 
-  constexpr variant& operator=(const variant&) = default;
-  constexpr variant& operator=(variant&&) = default;
+  _LIBCPP_HIDE_FROM_ABI constexpr variant& operator=(const variant&) = default;
+  _LIBCPP_HIDE_FROM_ABI constexpr variant& operator=(variant&&) = default;
 
   template <
       class _Arg,
index 40f73b8..40538f2 100644 (file)
@@ -2109,7 +2109,7 @@ public:
 private:
   class __destroy_vector {
     public:
-      _LIBCPP_CONSTEXPR __destroy_vector(vector& __vec) : __vec_(__vec) {}
+      _LIBCPP_CONSTEXPR _LIBCPP_HIDE_FROM_ABI __destroy_vector(vector& __vec) : __vec_(__vec) {}
 
       _LIBCPP_CONSTEXPR_SINCE_CXX20 _LIBCPP_HIDE_FROM_ABI void operator()() {
         if (__vec_.__begin_ != nullptr)
@@ -2306,7 +2306,7 @@ public:
     _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX20
     void clear() _NOEXCEPT {__size_ = 0;}
 
-    _LIBCPP_CONSTEXPR_SINCE_CXX20 void swap(vector&)
+    _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX20 void swap(vector&)
 #if _LIBCPP_STD_VER >= 14
         _NOEXCEPT;
 #else
index 9ae2536..38bf620 100644 (file)
 
 #include "hide_from_abi.hpp"
 
+namespace {
+AST_MATCHER(clang::ClassTemplateDecl, hasFullSpecializations) { return !Node.specializations().empty(); }
+AST_MATCHER(clang::CXXRecordDecl, isTrivial) { return Node.isTrivial(); }
+} // namespace
+
 namespace libcpp {
 hide_from_abi::hide_from_abi(llvm::StringRef name, clang::tidy::ClangTidyContext* context)
     : clang::tidy::ClangTidyCheck(name, context) {}
 
 void hide_from_abi::registerMatchers(clang::ast_matchers::MatchFinder* finder) {
   using namespace clang::ast_matchers;
+
+  auto has_hide_from_abi_attr = anyOf(hasAttr(clang::attr::Visibility), hasAttr(clang::attr::AbiTag));
+
   finder->addMatcher(
       functionDecl(
           unless(anyOf(
@@ -37,19 +45,66 @@ void hide_from_abi::registerMatchers(clang::ast_matchers::MatchFinder* finder) {
                          "__stable_partition",
                          "__lock_first",
                          "__stable_partition_impl"),
-              hasAttr(clang::attr::Visibility),
-              hasAttr(clang::attr::AbiTag),
+              has_hide_from_abi_attr,
               cxxMethodDecl(), // We have explicitly instantiated classes and some of their methods don't have these attributes
               isDeleted(),
               isConsteval())),
           isDefinition())
-          .bind("missing_hide_from_abi"),
+          .bind("hide_from_abi_on_free_function"),
       this);
+
+  auto on_trivial = allOf(
+      unless(isImplicit()), isDefaulted(), unless(ofClass(hasAncestor(classTemplateDecl()))), ofClass(isTrivial()));
+
+  // TODO: find a better way to check for explicit instantiations. Currently, every template that has a full
+  // specialization is ignored. For example, vector is ignored because we instantiate vector<double>
+  // in discrete_distribution.
+  finder->addMatcher(
+      cxxMethodDecl(
+          unless(anyOf(
+              has_hide_from_abi_attr,
+              isDeleted(),
+              isImplicit(),
+              hasAncestor(cxxRecordDecl(isLambda())),
+              ofClass(anyOf(hasAncestor(classTemplateDecl(hasFullSpecializations())),
+                            hasAnyName("basic_filebuf",
+                                       "basic_ifstream",
+                                       "basic_ofstream", // These are in the dylib in ABIv2
+                                       // TODO: fix the matcher to catch `sentry` instantiation.
+                                       "sentry"))),
+              isConsteval(),
+              hasParent(classTemplateSpecializationDecl()),
+              on_trivial)),
+          isDefinition())
+          .bind("hide_from_abi_on_member_function"),
+      this);
+
+  finder->addMatcher(
+      cxxMethodDecl(has_hide_from_abi_attr, on_trivial).bind("hide_from_abi_on_defaulted_smf_in_trivial_class"), this);
 }
 
 void hide_from_abi::check(const clang::ast_matchers::MatchFinder::MatchResult& result) {
-  if (const auto* call = result.Nodes.getNodeAs<clang::FunctionDecl>("missing_hide_from_abi"); call != nullptr) {
+  if (const auto* call = result.Nodes.getNodeAs<clang::FunctionDecl>("hide_from_abi_on_free_function");
+      call != nullptr) {
     diag(call->getBeginLoc(), "_LIBCPP_HIDE_FROM_ABI is missing");
   }
+
+  // The rest gets ignored in C++03 because it is subtly different in some cases.
+  // e.g. we change the definition of default constructors in some cases
+  // TODO: check whether we can remove thse differences
+  if (!result.Context->getLangOpts().CPlusPlus11)
+    return;
+
+  if (const auto* call = result.Nodes.getNodeAs<clang::CXXMethodDecl>("hide_from_abi_on_member_function");
+      call != nullptr) {
+    diag(call->getLocation(), "_LIBCPP_HIDE_FROM_ABI or _LIBCPP_HIDE_FROM_ABI_VIRTUAL is missing");
+  }
+
+  if (const auto* call =
+          result.Nodes.getNodeAs<clang::CXXMethodDecl>("hide_from_abi_on_defaulted_smf_in_trivial_class");
+      call != nullptr) {
+    diag(call->getLocation(),
+         "_LIBCPP_HIDE_FROM_ABI should not be used for special member functions in trivial classes");
+  }
 }
 } // namespace libcpp