mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2025-01-26 19:36:28 +00:00
Partially Revert "Workaround GCC bug PR78489 - SFINAE order is not respected."
This partially reverts commit r328261. The GCC bug has been fixed in trunk and has never existed in a released version. Therefore the changes to variant are unneeded. However, the additional tests have been left in place. llvm-svn: 328388
This commit is contained in:
parent
6a1f3446b5
commit
cd5e6a35bf
@ -1156,24 +1156,29 @@ public:
|
|||||||
: __impl(in_place_index<_Ip>, _VSTD::forward<_Arg>(__arg)) {}
|
: __impl(in_place_index<_Ip>, _VSTD::forward<_Arg>(__arg)) {}
|
||||||
|
|
||||||
template <size_t _Ip, class... _Args,
|
template <size_t _Ip, class... _Args,
|
||||||
enable_if_t<(_Ip < sizeof...(_Types)), size_t> _Ip2 = _Ip,
|
class = enable_if_t<(_Ip < sizeof...(_Types)), int>,
|
||||||
class _Tp = variant_alternative_t<_Ip2, variant<_Types...>>,
|
class _Tp = variant_alternative_t<_Ip, variant<_Types...>>,
|
||||||
enable_if_t<is_constructible<_Tp, _Args...>::value, int> = 0>
|
enable_if_t<is_constructible_v<_Tp, _Args...>, int> = 0>
|
||||||
inline _LIBCPP_INLINE_VISIBILITY
|
inline _LIBCPP_INLINE_VISIBILITY
|
||||||
explicit constexpr variant(in_place_index_t<_Ip>,
|
explicit constexpr variant(
|
||||||
_Args&&... __args)
|
in_place_index_t<_Ip>,
|
||||||
noexcept(is_nothrow_constructible_v<_Tp, _Args...>)
|
_Args&&... __args) noexcept(is_nothrow_constructible_v<_Tp, _Args...>)
|
||||||
: __impl(in_place_index<_Ip>, _VSTD::forward<_Args>(__args)...) {}
|
: __impl(in_place_index<_Ip>, _VSTD::forward<_Args>(__args)...) {}
|
||||||
|
|
||||||
template <size_t _Ip, class _Up, class... _Args,
|
template <
|
||||||
enable_if_t<(_Ip < sizeof...(_Types)), size_t> _Ip2 = _Ip,
|
size_t _Ip,
|
||||||
class _Tp = variant_alternative_t<_Ip2, variant<_Types...>>,
|
class _Up,
|
||||||
|
class... _Args,
|
||||||
|
enable_if_t<(_Ip < sizeof...(_Types)), int> = 0,
|
||||||
|
class _Tp = variant_alternative_t<_Ip, variant<_Types...>>,
|
||||||
enable_if_t<is_constructible_v<_Tp, initializer_list<_Up>&, _Args...>,
|
enable_if_t<is_constructible_v<_Tp, initializer_list<_Up>&, _Args...>,
|
||||||
int> = 0>
|
int> = 0>
|
||||||
inline _LIBCPP_INLINE_VISIBILITY
|
inline _LIBCPP_INLINE_VISIBILITY
|
||||||
explicit constexpr variant(in_place_index_t<_Ip>, initializer_list<_Up> __il,
|
explicit constexpr variant(
|
||||||
_Args&&... __args)
|
in_place_index_t<_Ip>,
|
||||||
noexcept(is_nothrow_constructible_v<_Tp, initializer_list<_Up>&, _Args...>)
|
initializer_list<_Up> __il,
|
||||||
|
_Args&&... __args) noexcept(
|
||||||
|
is_nothrow_constructible_v<_Tp, initializer_list<_Up>&, _Args...>)
|
||||||
: __impl(in_place_index<_Ip>, __il, _VSTD::forward<_Args>(__args)...) {}
|
: __impl(in_place_index<_Ip>, __il, _VSTD::forward<_Args>(__args)...) {}
|
||||||
|
|
||||||
template <
|
template <
|
||||||
|
Loading…
x
Reference in New Issue
Block a user