diff options
author | Casey Carter <Casey@Carter.net> | 2017-12-12 17:22:24 +0000 |
---|---|---|
committer | Casey Carter <Casey@Carter.net> | 2017-12-12 17:22:24 +0000 |
commit | 5f7683b2d2d9cfe5e4cff019cba906bc7a79bd29 (patch) | |
tree | 9ab02387ed59204eeec458524314a67ce0fac6f9 | |
parent | 4a3242f1dc891592de402243f9eae0d5abc40492 (diff) |
workaround PR 28385 in __find_exactly_one_checked
Fixes #35578.
Differential Revision: D41048
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@320500 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | include/tuple | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/include/tuple b/include/tuple index 788fd750b..5e32b6dfe 100644 --- a/include/tuple +++ b/include/tuple @@ -1012,10 +1012,10 @@ constexpr size_t __find_idx(size_t __i, const bool (&__matches)[_Nx]) { template <class _T1, class ..._Args> struct __find_exactly_one_checked { - static constexpr bool __matches[] = {is_same<_T1, _Args>::value...}; + static constexpr bool __matches[sizeof...(_Args)] = {is_same<_T1, _Args>::value...}; static constexpr size_t value = __find_detail::__find_idx(0, __matches); - static_assert (value != __not_found, "type not found in type list" ); - static_assert(value != __ambiguous,"type occurs more than once in type list"); + static_assert(value != __not_found, "type not found in type list" ); + static_assert(value != __ambiguous, "type occurs more than once in type list"); }; template <class _T1> |