Flatten tuple_constructible, tuple_convertible and tuple_assignable.
This patch is the last in a series that replaces recursive meta-programming in std::tuple with non-recursive implementations. Previously std::tuple could only be instantiated with 126 elements before it blew the max template instantiation depth. Now the size of std::tuple is essentially unbounded (I've tested with over 5000 elements). One unfortunate side-effect of this change is that tuple_constructible and similar no longer short circuit after the first failure. Instead they evaluate the conditions for all elements. This could be potentially breaking. I plan to look into this further. git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@274331 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -379,11 +379,6 @@ template <class ..._Tp>
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
void __swallow(_Tp&&...) _NOEXCEPT {}
|
||||
|
||||
template <bool ..._Pred>
|
||||
struct __all
|
||||
: is_same<__all<_Pred...>, __all<(_Pred, true)...>>
|
||||
{ };
|
||||
|
||||
template <class ..._Tp>
|
||||
struct __lazy_all : __all<_Tp::value...> {};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user