[libcxx-commits] [PATCH] D80069: [NFC] Remove no-variadic overloads of __allocator_traits_rebind.
Zoe Carver via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Sat May 16 14:49:48 PDT 2020
zoecarver created this revision.
zoecarver added a reviewer: ldionne.
Herald added subscribers: libcxx-commits, dexonsmith.
Herald added a project: libc++.
Herald added a reviewer: libc++.
All supported compilers have variadics so we can safely remove the overloads of __allocator_traits_rebind which are only enabled on compilers without variadics.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D80069
Files:
libcxx/include/memory
Index: libcxx/include/memory
===================================================================
--- libcxx/include/memory
+++ libcxx/include/memory
@@ -1306,8 +1306,6 @@
_LIBCPP_SUPPRESS_DEPRECATED_POP
};
-#ifndef _LIBCPP_HAS_NO_VARIADICS
-
template <template <class, class...> class _Alloc, class _Tp, class ..._Args, class _Up>
struct __allocator_traits_rebind<_Alloc<_Tp, _Args...>, _Up, true>
{
@@ -1322,62 +1320,6 @@
typedef _LIBCPP_NODEBUG_TYPE _Alloc<_Up, _Args...> type;
};
-#else // _LIBCPP_HAS_NO_VARIADICS
-
-template <template <class> class _Alloc, class _Tp, class _Up>
-struct __allocator_traits_rebind<_Alloc<_Tp>, _Up, true>
-{
- typedef typename _Alloc<_Tp>::template rebind<_Up>::other type;
-};
-
-template <template <class> class _Alloc, class _Tp, class _Up>
-struct __allocator_traits_rebind<_Alloc<_Tp>, _Up, false>
-{
- typedef _Alloc<_Up> type;
-};
-
-template <template <class, class> class _Alloc, class _Tp, class _A0, class _Up>
-struct __allocator_traits_rebind<_Alloc<_Tp, _A0>, _Up, true>
-{
- typedef typename _Alloc<_Tp, _A0>::template rebind<_Up>::other type;
-};
-
-template <template <class, class> class _Alloc, class _Tp, class _A0, class _Up>
-struct __allocator_traits_rebind<_Alloc<_Tp, _A0>, _Up, false>
-{
- typedef _Alloc<_Up, _A0> type;
-};
-
-template <template <class, class, class> class _Alloc, class _Tp, class _A0,
- class _A1, class _Up>
-struct __allocator_traits_rebind<_Alloc<_Tp, _A0, _A1>, _Up, true>
-{
- typedef typename _Alloc<_Tp, _A0, _A1>::template rebind<_Up>::other type;
-};
-
-template <template <class, class, class> class _Alloc, class _Tp, class _A0,
- class _A1, class _Up>
-struct __allocator_traits_rebind<_Alloc<_Tp, _A0, _A1>, _Up, false>
-{
- typedef _Alloc<_Up, _A0, _A1> type;
-};
-
-template <template <class, class, class, class> class _Alloc, class _Tp, class _A0,
- class _A1, class _A2, class _Up>
-struct __allocator_traits_rebind<_Alloc<_Tp, _A0, _A1, _A2>, _Up, true>
-{
- typedef typename _Alloc<_Tp, _A0, _A1, _A2>::template rebind<_Up>::other type;
-};
-
-template <template <class, class, class, class> class _Alloc, class _Tp, class _A0,
- class _A1, class _A2, class _Up>
-struct __allocator_traits_rebind<_Alloc<_Tp, _A0, _A1, _A2>, _Up, false>
-{
- typedef _Alloc<_Up, _A0, _A1, _A2> type;
-};
-
-#endif // _LIBCPP_HAS_NO_VARIADICS
-
#ifndef _LIBCPP_CXX03_LANG
_LIBCPP_SUPPRESS_DEPRECATED_PUSH
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D80069.264455.patch
Type: text/x-patch
Size: 2613 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20200516/9ce29572/attachment.bin>
More information about the libcxx-commits
mailing list