[libcxx-commits] [libcxx] 640e2ba - [libc++] Mark everything in <deque> as _LIBCPP_HIDE_FROM_ABI and replace _LIBCPP_INLINE_VISIBILITY

Nikolas Klauser via libcxx-commits libcxx-commits at lists.llvm.org
Sat Aug 27 13:01:10 PDT 2022


Author: Nikolas Klauser
Date: 2022-08-27T22:01:00+02:00
New Revision: 640e2bae5090339da91a73b980eef4f70670a1e5

URL: https://github.com/llvm/llvm-project/commit/640e2bae5090339da91a73b980eef4f70670a1e5
DIFF: https://github.com/llvm/llvm-project/commit/640e2bae5090339da91a73b980eef4f70670a1e5.diff

LOG: [libc++] Mark everything in <deque> as _LIBCPP_HIDE_FROM_ABI and replace _LIBCPP_INLINE_VISIBILITY

Reviewed By: ldionne, #libc

Spies: libcxx-commits

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

Added: 
    

Modified: 
    libcxx/include/deque

Removed: 
    


################################################################################
diff  --git a/libcxx/include/deque b/libcxx/include/deque
index c758327595405..4a5136b3500f7 100644
--- a/libcxx/include/deque
+++ b/libcxx/include/deque
@@ -339,22 +339,22 @@ public:
     typedef random_access_iterator_tag  iterator_category;
     typedef _Reference                  reference;
 
-    _LIBCPP_INLINE_VISIBILITY __deque_iterator() _NOEXCEPT
+    _LIBCPP_HIDE_FROM_ABI __deque_iterator() _NOEXCEPT
 #if _LIBCPP_STD_VER > 11
      : __m_iter_(nullptr), __ptr_(nullptr)
 #endif
      {}
 
     template <class _Pp, class _Rp, class _MP>
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     __deque_iterator(const __deque_iterator<value_type, _Pp, _Rp, _MP, 
diff erence_type, _BS>& __it,
                 typename enable_if<is_convertible<_Pp, pointer>::value>::type* = 0) _NOEXCEPT
         : __m_iter_(__it.__m_iter_), __ptr_(__it.__ptr_) {}
 
-    _LIBCPP_INLINE_VISIBILITY reference operator*() const {return *__ptr_;}
-    _LIBCPP_INLINE_VISIBILITY pointer operator->() const {return __ptr_;}
+    _LIBCPP_HIDE_FROM_ABI reference operator*() const {return *__ptr_;}
+    _LIBCPP_HIDE_FROM_ABI pointer operator->() const {return __ptr_;}
 
-    _LIBCPP_INLINE_VISIBILITY __deque_iterator& operator++()
+    _LIBCPP_HIDE_FROM_ABI __deque_iterator& operator++()
     {
         if (++__ptr_ - *__m_iter_ == __block_size)
         {
@@ -364,14 +364,14 @@ public:
         return *this;
     }
 
-    _LIBCPP_INLINE_VISIBILITY __deque_iterator operator++(int)
+    _LIBCPP_HIDE_FROM_ABI __deque_iterator operator++(int)
     {
         __deque_iterator __tmp = *this;
         ++(*this);
         return __tmp;
     }
 
-    _LIBCPP_INLINE_VISIBILITY __deque_iterator& operator--()
+    _LIBCPP_HIDE_FROM_ABI __deque_iterator& operator--()
     {
         if (__ptr_ == *__m_iter_)
         {
@@ -382,14 +382,14 @@ public:
         return *this;
     }
 
-    _LIBCPP_INLINE_VISIBILITY __deque_iterator operator--(int)
+    _LIBCPP_HIDE_FROM_ABI __deque_iterator operator--(int)
     {
         __deque_iterator __tmp = *this;
         --(*this);
         return __tmp;
     }
 
-    _LIBCPP_INLINE_VISIBILITY __deque_iterator& operator+=(
diff erence_type __n)
+    _LIBCPP_HIDE_FROM_ABI __deque_iterator& operator+=(
diff erence_type __n)
     {
         if (__n != 0)
         {
@@ -409,30 +409,30 @@ public:
         return *this;
     }
 
-    _LIBCPP_INLINE_VISIBILITY __deque_iterator& operator-=(
diff erence_type __n)
+    _LIBCPP_HIDE_FROM_ABI __deque_iterator& operator-=(
diff erence_type __n)
     {
         return *this += -__n;
     }
 
-    _LIBCPP_INLINE_VISIBILITY __deque_iterator operator+(
diff erence_type __n) const
+    _LIBCPP_HIDE_FROM_ABI __deque_iterator operator+(
diff erence_type __n) const
     {
         __deque_iterator __t(*this);
         __t += __n;
         return __t;
     }
 
-    _LIBCPP_INLINE_VISIBILITY __deque_iterator operator-(
diff erence_type __n) const
+    _LIBCPP_HIDE_FROM_ABI __deque_iterator operator-(
diff erence_type __n) const
     {
         __deque_iterator __t(*this);
         __t -= __n;
         return __t;
     }
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     friend __deque_iterator operator+(
diff erence_type __n, const __deque_iterator& __it)
         {return __it + __n;}
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     friend 
diff erence_type operator-(const __deque_iterator& __x, const __deque_iterator& __y)
     {
         if (__x != __y)
@@ -442,36 +442,36 @@ public:
         return 0;
     }
 
-    _LIBCPP_INLINE_VISIBILITY reference operator[](
diff erence_type __n) const
+    _LIBCPP_HIDE_FROM_ABI reference operator[](
diff erence_type __n) const
         {return *(*this + __n);}
 
-    _LIBCPP_INLINE_VISIBILITY friend
+    _LIBCPP_HIDE_FROM_ABI friend
         bool operator==(const __deque_iterator& __x, const __deque_iterator& __y)
         {return __x.__ptr_ == __y.__ptr_;}
 
-    _LIBCPP_INLINE_VISIBILITY friend
+    _LIBCPP_HIDE_FROM_ABI friend
         bool operator!=(const __deque_iterator& __x, const __deque_iterator& __y)
         {return !(__x == __y);}
 
-    _LIBCPP_INLINE_VISIBILITY friend
+    _LIBCPP_HIDE_FROM_ABI friend
         bool operator<(const __deque_iterator& __x, const __deque_iterator& __y)
         {return __x.__m_iter_ < __y.__m_iter_ ||
                (__x.__m_iter_ == __y.__m_iter_ && __x.__ptr_ < __y.__ptr_);}
 
-    _LIBCPP_INLINE_VISIBILITY friend
+    _LIBCPP_HIDE_FROM_ABI friend
         bool operator>(const __deque_iterator& __x, const __deque_iterator& __y)
         {return __y < __x;}
 
-    _LIBCPP_INLINE_VISIBILITY friend
+    _LIBCPP_HIDE_FROM_ABI friend
         bool operator<=(const __deque_iterator& __x, const __deque_iterator& __y)
         {return !(__y < __x);}
 
-    _LIBCPP_INLINE_VISIBILITY friend
+    _LIBCPP_HIDE_FROM_ABI friend
         bool operator>=(const __deque_iterator& __x, const __deque_iterator& __y)
         {return !(__x < __y);}
 
 private:
-    _LIBCPP_INLINE_VISIBILITY explicit __deque_iterator(__map_iterator __m, pointer __p) _NOEXCEPT
+    _LIBCPP_HIDE_FROM_ABI explicit __deque_iterator(__map_iterator __m, pointer __p) _NOEXCEPT
         : __m_iter_(__m), __ptr_(__p) {}
 
     template <class _Tp, class _Ap> friend class _LIBCPP_TEMPLATE_VIS deque;
@@ -984,7 +984,8 @@ public:
 
 private:
   struct __deque_block_range {
-    explicit __deque_block_range(pointer __b, pointer __e) _NOEXCEPT : __begin_(__b), __end_(__e) {}
+    explicit _LIBCPP_HIDE_FROM_ABI
+    __deque_block_range(pointer __b, pointer __e) _NOEXCEPT : __begin_(__b), __end_(__e) {}
     const pointer __begin_;
     const pointer __end_;
   };
@@ -993,28 +994,28 @@ private:
     iterator __pos_;
     const iterator __end_;
 
-    __deque_range(iterator __pos, iterator __e) _NOEXCEPT
+    _LIBCPP_HIDE_FROM_ABI __deque_range(iterator __pos, iterator __e) _NOEXCEPT
       : __pos_(__pos), __end_(__e) {}
 
-    explicit operator bool() const _NOEXCEPT {
+    explicit _LIBCPP_HIDE_FROM_ABI operator bool() const _NOEXCEPT {
       return __pos_ != __end_;
     }
 
-    __deque_range begin() const {
+    _LIBCPP_HIDE_FROM_ABI __deque_range begin() const {
       return *this;
     }
 
-    __deque_range end() const {
+    _LIBCPP_HIDE_FROM_ABI __deque_range end() const {
       return __deque_range(__end_, __end_);
     }
-    __deque_block_range operator*() const _NOEXCEPT {
+    _LIBCPP_HIDE_FROM_ABI __deque_block_range operator*() const _NOEXCEPT {
         if (__pos_.__m_iter_ == __end_.__m_iter_) {
         return __deque_block_range(__pos_.__ptr_, __end_.__ptr_);
       }
       return __deque_block_range(__pos_.__ptr_, *__pos_.__m_iter_ + __block_size);
     }
 
-    __deque_range& operator++() _NOEXCEPT {
+    _LIBCPP_HIDE_FROM_ABI __deque_range& operator++() _NOEXCEPT {
       if (__pos_.__m_iter_ == __end_.__m_iter_) {
         __pos_ = __end_;
       } else {
@@ -1034,11 +1035,11 @@ private:
   };
 
   struct _ConstructTransaction {
-    _ConstructTransaction(deque* __db, __deque_block_range& __r)
+    _LIBCPP_HIDE_FROM_ABI _ConstructTransaction(deque* __db, __deque_block_range& __r)
       : __pos_(__r.__begin_), __end_(__r.__end_), __begin_(__r.__begin_), __base_(__db) {}
 
 
-    ~_ConstructTransaction() {
+    _LIBCPP_HIDE_FROM_ABI ~_ConstructTransaction() {
       __base_->__size() += (__pos_ - __begin_);
     }
 
@@ -1058,7 +1059,7 @@ private:
 public:
 
     // construct/copy/destroy:
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     deque() _NOEXCEPT_(is_nothrow_default_constructible<allocator_type>::value)
         : __start_(0), __size_(0, __default_init_tag()) {}
 
@@ -1070,17 +1071,17 @@ public:
           __alloc_traits::deallocate(__alloc(), *__i, __block_size);
     }
 
-    _LIBCPP_INLINE_VISIBILITY explicit deque(const allocator_type& __a)
+    _LIBCPP_HIDE_FROM_ABI explicit deque(const allocator_type& __a)
         : __map_(__pointer_allocator(__a)), __start_(0), __size_(0, __a) {}
 
-    explicit deque(size_type __n);
+    explicit _LIBCPP_HIDE_FROM_ABI deque(size_type __n);
 #if _LIBCPP_STD_VER > 11
-    explicit deque(size_type __n, const _Allocator& __a);
+    explicit _LIBCPP_HIDE_FROM_ABI deque(size_type __n, const _Allocator& __a);
 #endif
-    deque(size_type __n, const value_type& __v);
+    _LIBCPP_HIDE_FROM_ABI deque(size_type __n, const value_type& __v);
 
     template <class = __enable_if_t<__is_allocator<_Allocator>::value> >
-    deque(size_type __n, const value_type& __v, const allocator_type& __a)
+    _LIBCPP_HIDE_FROM_ABI deque(size_type __n, const value_type& __v, const allocator_type& __a)
         : __map_(__pointer_allocator(__a)), __start_(0), __size_(0, __a)
     {
         if (__n > 0)
@@ -1088,46 +1089,46 @@ public:
     }
 
     template <class _InputIter>
-        deque(_InputIter __f, _InputIter __l,
+    _LIBCPP_HIDE_FROM_ABI deque(_InputIter __f, _InputIter __l,
               typename enable_if<__is_cpp17_input_iterator<_InputIter>::value>::type* = 0);
     template <class _InputIter>
-        deque(_InputIter __f, _InputIter __l, const allocator_type& __a,
+    _LIBCPP_HIDE_FROM_ABI deque(_InputIter __f, _InputIter __l, const allocator_type& __a,
               typename enable_if<__is_cpp17_input_iterator<_InputIter>::value>::type* = 0);
-    deque(const deque& __c);
-    deque(const deque& __c, const __type_identity_t<allocator_type>& __a);
+    _LIBCPP_HIDE_FROM_ABI deque(const deque& __c);
+    _LIBCPP_HIDE_FROM_ABI deque(const deque& __c, const __type_identity_t<allocator_type>& __a);
 
-    deque& operator=(const deque& __c);
+    _LIBCPP_HIDE_FROM_ABI deque& operator=(const deque& __c);
 
 #ifndef _LIBCPP_CXX03_LANG
-    deque(initializer_list<value_type> __il);
-    deque(initializer_list<value_type> __il, const allocator_type& __a);
+    _LIBCPP_HIDE_FROM_ABI deque(initializer_list<value_type> __il);
+    _LIBCPP_HIDE_FROM_ABI deque(initializer_list<value_type> __il, const allocator_type& __a);
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     deque& operator=(initializer_list<value_type> __il) {assign(__il); return *this;}
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     deque(deque&& __c) _NOEXCEPT_(is_nothrow_move_constructible<allocator_type>::value);
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     deque(deque&& __c, const __type_identity_t<allocator_type>& __a);
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     deque& operator=(deque&& __c)
         _NOEXCEPT_(__alloc_traits::propagate_on_container_move_assignment::value &&
                    is_nothrow_move_assignable<allocator_type>::value);
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     void assign(initializer_list<value_type> __il) {assign(__il.begin(), __il.end());}
 #endif // _LIBCPP_CXX03_LANG
 
     template <class _InputIter>
-        void assign(_InputIter __f, _InputIter __l,
+    _LIBCPP_HIDE_FROM_ABI void assign(_InputIter __f, _InputIter __l,
                     typename enable_if<__is_cpp17_input_iterator<_InputIter>::value &&
                                       !__is_cpp17_random_access_iterator<_InputIter>::value>::type* = 0);
     template <class _RAIter>
-        void assign(_RAIter __f, _RAIter __l,
+    _LIBCPP_HIDE_FROM_ABI void assign(_RAIter __f, _RAIter __l,
                     typename enable_if<__is_cpp17_random_access_iterator<_RAIter>::value>::type* = 0);
-    void assign(size_type __n, const value_type& __v);
+    _LIBCPP_HIDE_FROM_ABI void assign(size_type __n, const value_type& __v);
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     allocator_type get_allocator() const _NOEXCEPT;
   _LIBCPP_HIDE_FROM_ABI allocator_type& __alloc() _NOEXCEPT { return __size_.second(); }
   _LIBCPP_HIDE_FROM_ABI const allocator_type& __alloc() const _NOEXCEPT { return __size_.second(); }
@@ -1157,107 +1158,107 @@ public:
       return const_iterator(__mp, __map_.empty() ? 0 : *__mp + __p % __block_size);
   }
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     reverse_iterator       rbegin() _NOEXCEPT
         {return       reverse_iterator(end());}
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     const_reverse_iterator rbegin() const _NOEXCEPT
         {return const_reverse_iterator(end());}
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     reverse_iterator       rend() _NOEXCEPT
         {return       reverse_iterator(begin());}
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     const_reverse_iterator rend()   const _NOEXCEPT
         {return const_reverse_iterator(begin());}
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     const_iterator         cbegin()  const _NOEXCEPT
         {return begin();}
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     const_iterator         cend()    const _NOEXCEPT
         {return end();}
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     const_reverse_iterator crbegin() const _NOEXCEPT
         {return const_reverse_iterator(end());}
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     const_reverse_iterator crend()   const _NOEXCEPT
         {return const_reverse_iterator(begin());}
 
     // capacity:
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     size_type size() const _NOEXCEPT {return __size();}
 
   _LIBCPP_HIDE_FROM_ABI size_type& __size() _NOEXCEPT { return __size_.first(); }
   _LIBCPP_HIDE_FROM_ABI const size_type& __size() const _NOEXCEPT { return __size_.first(); }
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     size_type max_size() const _NOEXCEPT
         {return _VSTD::min<size_type>(
             __alloc_traits::max_size(__alloc()),
             numeric_limits<
diff erence_type>::max());}
-    void resize(size_type __n);
-    void resize(size_type __n, const value_type& __v);
-    void shrink_to_fit() _NOEXCEPT;
-    _LIBCPP_NODISCARD_AFTER_CXX17 _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI void resize(size_type __n);
+    _LIBCPP_HIDE_FROM_ABI void resize(size_type __n, const value_type& __v);
+    _LIBCPP_HIDE_FROM_ABI void shrink_to_fit() _NOEXCEPT;
+    _LIBCPP_NODISCARD_AFTER_CXX17 _LIBCPP_HIDE_FROM_ABI
     bool empty() const _NOEXCEPT {return size() == 0;}
 
     // element access:
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     reference operator[](size_type __i) _NOEXCEPT;
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     const_reference operator[](size_type __i) const _NOEXCEPT;
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     reference at(size_type __i);
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     const_reference at(size_type __i) const;
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     reference front() _NOEXCEPT;
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     const_reference front() const _NOEXCEPT;
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     reference back() _NOEXCEPT;
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     const_reference back() const _NOEXCEPT;
 
     // 23.2.2.3 modifiers:
-    void push_front(const value_type& __v);
-    void push_back(const value_type& __v);
+    _LIBCPP_HIDE_FROM_ABI void push_front(const value_type& __v);
+    _LIBCPP_HIDE_FROM_ABI void push_back(const value_type& __v);
 #ifndef _LIBCPP_CXX03_LANG
 #if _LIBCPP_STD_VER > 14
-    template <class... _Args> reference emplace_front(_Args&&... __args);
-    template <class... _Args> reference emplace_back (_Args&&... __args);
+    template <class... _Args> _LIBCPP_HIDE_FROM_ABI reference emplace_front(_Args&&... __args);
+    template <class... _Args> _LIBCPP_HIDE_FROM_ABI reference emplace_back (_Args&&... __args);
 #else
-    template <class... _Args> void      emplace_front(_Args&&... __args);
-    template <class... _Args> void      emplace_back (_Args&&... __args);
+    template <class... _Args> _LIBCPP_HIDE_FROM_ABI void      emplace_front(_Args&&... __args);
+    template <class... _Args> _LIBCPP_HIDE_FROM_ABI void      emplace_back (_Args&&... __args);
 #endif
-    template <class... _Args> iterator emplace(const_iterator __p, _Args&&... __args);
+    template <class... _Args> _LIBCPP_HIDE_FROM_ABI iterator emplace(const_iterator __p, _Args&&... __args);
 
-    void push_front(value_type&& __v);
-    void push_back(value_type&& __v);
-    iterator insert(const_iterator __p, value_type&& __v);
+    _LIBCPP_HIDE_FROM_ABI void push_front(value_type&& __v);
+    _LIBCPP_HIDE_FROM_ABI void push_back(value_type&& __v);
+    _LIBCPP_HIDE_FROM_ABI iterator insert(const_iterator __p, value_type&& __v);
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     iterator insert(const_iterator __p, initializer_list<value_type> __il)
         {return insert(__p, __il.begin(), __il.end());}
 #endif // _LIBCPP_CXX03_LANG
-    iterator insert(const_iterator __p, const value_type& __v);
-    iterator insert(const_iterator __p, size_type __n, const value_type& __v);
+    _LIBCPP_HIDE_FROM_ABI iterator insert(const_iterator __p, const value_type& __v);
+    _LIBCPP_HIDE_FROM_ABI iterator insert(const_iterator __p, size_type __n, const value_type& __v);
     template <class _InputIter>
-        iterator insert(const_iterator __p, _InputIter __f, _InputIter __l,
+    _LIBCPP_HIDE_FROM_ABI iterator insert(const_iterator __p, _InputIter __f, _InputIter __l,
                          typename enable_if<__is_exactly_cpp17_input_iterator<_InputIter>::value>::type* = 0);
     template <class _ForwardIterator>
-        iterator insert(const_iterator __p, _ForwardIterator __f, _ForwardIterator __l,
+    _LIBCPP_HIDE_FROM_ABI iterator insert(const_iterator __p, _ForwardIterator __f, _ForwardIterator __l,
                         typename enable_if<__is_exactly_cpp17_forward_iterator<_ForwardIterator>::value>::type* = 0);
     template <class _BiIter>
-        iterator insert(const_iterator __p, _BiIter __f, _BiIter __l,
+    _LIBCPP_HIDE_FROM_ABI iterator insert(const_iterator __p, _BiIter __f, _BiIter __l,
                          typename enable_if<__is_cpp17_bidirectional_iterator<_BiIter>::value>::type* = 0);
 
-    void pop_front();
-    void pop_back();
-    iterator erase(const_iterator __p);
-    iterator erase(const_iterator __f, const_iterator __l);
+    _LIBCPP_HIDE_FROM_ABI void pop_front();
+    _LIBCPP_HIDE_FROM_ABI void pop_back();
+    _LIBCPP_HIDE_FROM_ABI iterator erase(const_iterator __p);
+    _LIBCPP_HIDE_FROM_ABI iterator erase(const_iterator __f, const_iterator __l);
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     void swap(deque& __c)
 #if _LIBCPP_STD_VER >= 14
         _NOEXCEPT;
@@ -1265,10 +1266,10 @@ public:
         _NOEXCEPT_(!__alloc_traits::propagate_on_container_swap::value ||
                    __is_nothrow_swappable<allocator_type>::value);
 #endif
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     void clear() _NOEXCEPT;
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     bool __invariants() const {
         if (!__map_.__invariants())
             return false;
@@ -1295,25 +1296,25 @@ public:
         return true;
     }
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     void __move_assign_alloc(deque& __c)
         _NOEXCEPT_(!__alloc_traits::propagate_on_container_move_assignment::value ||
                    is_nothrow_move_assignable<allocator_type>::value)
         {__move_assign_alloc(__c, integral_constant<bool,
                       __alloc_traits::propagate_on_container_move_assignment::value>());}
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     void __move_assign_alloc(deque& __c, true_type)
         _NOEXCEPT_(is_nothrow_move_assignable<allocator_type>::value)
         {
             __alloc() = _VSTD::move(__c.__alloc());
         }
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     void __move_assign_alloc(deque&, false_type) _NOEXCEPT
         {}
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     void __move_assign(deque& __c)
         _NOEXCEPT_(__alloc_traits::propagate_on_container_move_assignment::value &&
                    is_nothrow_move_assignable<allocator_type>::value)
@@ -1325,43 +1326,43 @@ public:
         __c.__start_ = __c.__size() = 0;
     }
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     static size_type __recommend_blocks(size_type __n)
     {
         return __n / __block_size + (__n % __block_size != 0);
     }
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     size_type __capacity() const
     {
         return __map_.size() == 0 ? 0 : __map_.size() * __block_size - 1;
     }
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     size_type __block_count() const
     {
         return __map_.size();
     }
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     size_type __front_spare() const
     {
         return __start_;
     }
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     size_type __front_spare_blocks() const {
       return __front_spare() / __block_size;
     }
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     size_type __back_spare() const
     {
         return __capacity() - (__start_ + size());
     }
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     size_type __back_spare_blocks() const {
       return __back_spare() / __block_size;
     }
 
  private:
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     bool __maybe_remove_front_spare(bool __keep_one = true) {
       if (__front_spare_blocks() >= 2 || (!__keep_one && __front_spare_blocks())) {
         __alloc_traits::deallocate(__alloc(), __map_.front(),
@@ -1373,7 +1374,7 @@ public:
       return false;
     }
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     bool __maybe_remove_back_spare(bool __keep_one = true) {
       if (__back_spare_blocks() >= 2 || (!__keep_one && __back_spare_blocks())) {
         __alloc_traits::deallocate(__alloc(), __map_.back(),
@@ -1385,33 +1386,33 @@ public:
     }
 
     template <class _InpIter>
-        void __append(_InpIter __f, _InpIter __l,
+    _LIBCPP_HIDE_FROM_ABI void __append(_InpIter __f, _InpIter __l,
                  typename enable_if<__is_exactly_cpp17_input_iterator<_InpIter>::value>::type* = 0);
     template <class _ForIter>
-        void __append(_ForIter __f, _ForIter __l,
+    _LIBCPP_HIDE_FROM_ABI void __append(_ForIter __f, _ForIter __l,
                       typename enable_if<__is_cpp17_forward_iterator<_ForIter>::value>::type* = 0);
-    void __append(size_type __n);
-    void __append(size_type __n, const value_type& __v);
-    void __erase_to_end(const_iterator __f);
-    void __add_front_capacity();
-    void __add_front_capacity(size_type __n);
-    void __add_back_capacity();
-    void __add_back_capacity(size_type __n);
-    iterator __move_and_check(iterator __f, iterator __l, iterator __r,
+    _LIBCPP_HIDE_FROM_ABI void __append(size_type __n);
+    _LIBCPP_HIDE_FROM_ABI void __append(size_type __n, const value_type& __v);
+    _LIBCPP_HIDE_FROM_ABI void __erase_to_end(const_iterator __f);
+    _LIBCPP_HIDE_FROM_ABI void __add_front_capacity();
+    _LIBCPP_HIDE_FROM_ABI void __add_front_capacity(size_type __n);
+    _LIBCPP_HIDE_FROM_ABI void __add_back_capacity();
+    _LIBCPP_HIDE_FROM_ABI void __add_back_capacity(size_type __n);
+    _LIBCPP_HIDE_FROM_ABI iterator __move_and_check(iterator __f, iterator __l, iterator __r,
                               const_pointer& __vt);
-    iterator __move_backward_and_check(iterator __f, iterator __l, iterator __r,
+    _LIBCPP_HIDE_FROM_ABI iterator __move_backward_and_check(iterator __f, iterator __l, iterator __r,
                                        const_pointer& __vt);
-    void __move_construct_and_check(iterator __f, iterator __l,
+    _LIBCPP_HIDE_FROM_ABI void __move_construct_and_check(iterator __f, iterator __l,
                                     iterator __r, const_pointer& __vt);
-    void __move_construct_backward_and_check(iterator __f, iterator __l,
+    _LIBCPP_HIDE_FROM_ABI void __move_construct_backward_and_check(iterator __f, iterator __l,
                                              iterator __r, const_pointer& __vt);
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     void __copy_assign_alloc(const deque& __c)
         {__copy_assign_alloc(__c, integral_constant<bool,
                       __alloc_traits::propagate_on_container_copy_assignment::value>());}
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     void __copy_assign_alloc(const deque& __c, true_type)
         {
             if (__alloc() != __c.__alloc())
@@ -1423,13 +1424,13 @@ public:
             __map_.__alloc() = __c.__map_.__alloc();
         }
 
-    _LIBCPP_INLINE_VISIBILITY
+    _LIBCPP_HIDE_FROM_ABI
     void __copy_assign_alloc(const deque&, false_type)
         {}
 
-    void __move_assign(deque& __c, true_type)
+    _LIBCPP_HIDE_FROM_ABI void __move_assign(deque& __c, true_type)
         _NOEXCEPT_(is_nothrow_move_assignable<allocator_type>::value);
-    void __move_assign(deque& __c, false_type);
+    _LIBCPP_HIDE_FROM_ABI void __move_assign(deque& __c, false_type);
 };
 
 template <class _Tp, class _Alloc>
@@ -2844,7 +2845,7 @@ deque<_Tp, _Allocator>::clear() _NOEXCEPT
 }
 
 template <class _Tp, class _Allocator>
-inline _LIBCPP_INLINE_VISIBILITY
+inline _LIBCPP_HIDE_FROM_ABI
 bool
 operator==(const deque<_Tp, _Allocator>& __x, const deque<_Tp, _Allocator>& __y)
 {
@@ -2853,7 +2854,7 @@ operator==(const deque<_Tp, _Allocator>& __x, const deque<_Tp, _Allocator>& __y)
 }
 
 template <class _Tp, class _Allocator>
-inline _LIBCPP_INLINE_VISIBILITY
+inline _LIBCPP_HIDE_FROM_ABI
 bool
 operator!=(const deque<_Tp, _Allocator>& __x, const deque<_Tp, _Allocator>& __y)
 {
@@ -2861,7 +2862,7 @@ operator!=(const deque<_Tp, _Allocator>& __x, const deque<_Tp, _Allocator>& __y)
 }
 
 template <class _Tp, class _Allocator>
-inline _LIBCPP_INLINE_VISIBILITY
+inline _LIBCPP_HIDE_FROM_ABI
 bool
 operator< (const deque<_Tp, _Allocator>& __x, const deque<_Tp, _Allocator>& __y)
 {
@@ -2869,7 +2870,7 @@ operator< (const deque<_Tp, _Allocator>& __x, const deque<_Tp, _Allocator>& __y)
 }
 
 template <class _Tp, class _Allocator>
-inline _LIBCPP_INLINE_VISIBILITY
+inline _LIBCPP_HIDE_FROM_ABI
 bool
 operator> (const deque<_Tp, _Allocator>& __x, const deque<_Tp, _Allocator>& __y)
 {
@@ -2877,7 +2878,7 @@ operator> (const deque<_Tp, _Allocator>& __x, const deque<_Tp, _Allocator>& __y)
 }
 
 template <class _Tp, class _Allocator>
-inline _LIBCPP_INLINE_VISIBILITY
+inline _LIBCPP_HIDE_FROM_ABI
 bool
 operator>=(const deque<_Tp, _Allocator>& __x, const deque<_Tp, _Allocator>& __y)
 {
@@ -2885,7 +2886,7 @@ operator>=(const deque<_Tp, _Allocator>& __x, const deque<_Tp, _Allocator>& __y)
 }
 
 template <class _Tp, class _Allocator>
-inline _LIBCPP_INLINE_VISIBILITY
+inline _LIBCPP_HIDE_FROM_ABI
 bool
 operator<=(const deque<_Tp, _Allocator>& __x, const deque<_Tp, _Allocator>& __y)
 {
@@ -2893,7 +2894,7 @@ operator<=(const deque<_Tp, _Allocator>& __x, const deque<_Tp, _Allocator>& __y)
 }
 
 template <class _Tp, class _Allocator>
-inline _LIBCPP_INLINE_VISIBILITY
+inline _LIBCPP_HIDE_FROM_ABI
 void
 swap(deque<_Tp, _Allocator>& __x, deque<_Tp, _Allocator>& __y)
     _NOEXCEPT_(_NOEXCEPT_(__x.swap(__y)))
@@ -2903,7 +2904,7 @@ swap(deque<_Tp, _Allocator>& __x, deque<_Tp, _Allocator>& __y)
 
 #if _LIBCPP_STD_VER > 17
 template <class _Tp, class _Allocator, class _Up>
-inline _LIBCPP_INLINE_VISIBILITY typename deque<_Tp, _Allocator>::size_type
+inline _LIBCPP_HIDE_FROM_ABI typename deque<_Tp, _Allocator>::size_type
 erase(deque<_Tp, _Allocator>& __c, const _Up& __v) {
   auto __old_size = __c.size();
   __c.erase(_VSTD::remove(__c.begin(), __c.end(), __v), __c.end());
@@ -2911,7 +2912,7 @@ erase(deque<_Tp, _Allocator>& __c, const _Up& __v) {
 }
 
 template <class _Tp, class _Allocator, class _Predicate>
-inline _LIBCPP_INLINE_VISIBILITY typename deque<_Tp, _Allocator>::size_type
+inline _LIBCPP_HIDE_FROM_ABI typename deque<_Tp, _Allocator>::size_type
 erase_if(deque<_Tp, _Allocator>& __c, _Predicate __pred) {
   auto __old_size = __c.size();
   __c.erase(_VSTD::remove_if(__c.begin(), __c.end(), __pred), __c.end());


        


More information about the libcxx-commits mailing list