From 2b7e475f996a8a4a54dfad260c67db9eeef925f7 Mon Sep 17 00:00:00 2001 From: Michael Schellenberger Costa Date: Wed, 1 May 2024 23:24:09 +0200 Subject: [PATCH] Fix unqualified calls to `__swallow` Fixes [BUG]: libcudacxx clashes w/ libc++: ambiguous overload resolution for `__swallow` #1678 --- libcudacxx/include/cuda/std/detail/libcxx/include/tuple | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/libcudacxx/include/cuda/std/detail/libcxx/include/tuple b/libcudacxx/include/cuda/std/detail/libcxx/include/tuple index 22cb1d51fe8..778fa73b80d 100644 --- a/libcudacxx/include/cuda/std/detail/libcxx/include/tuple +++ b/libcudacxx/include/cuda/std/detail/libcxx/include/tuple @@ -494,7 +494,7 @@ struct _LIBCUDACXX_DECLSPEC_EMPTY_BASES __tuple_impl<__tuple_indices<_Indx...>, _LIBCUDACXX_INLINE_VISIBILITY __tuple_impl& operator=(_Tuple&& __t) noexcept( (__all<_LIBCUDACXX_TRAIT(is_nothrow_assignable, _Tp&, __tuple_elem_at<_Tuple, _Indx>)...>::value)) { - __swallow(__tuple_leaf<_Indx, _Tp>::operator=( + _CUDA_VSTD::__swallow(__tuple_leaf<_Indx, _Tp>::operator=( _CUDA_VSTD::forward<__tuple_elem_at<_Tuple, _Indx>>(_CUDA_VSTD::get<_Indx>(__t)))...); return *this; } @@ -505,14 +505,15 @@ struct _LIBCUDACXX_DECLSPEC_EMPTY_BASES __tuple_impl<__tuple_indices<_Indx...>, _LIBCUDACXX_INLINE_VISIBILITY __tuple_impl& operator=(const __tuple_impl& __t) noexcept((__all<_LIBCUDACXX_TRAIT(is_nothrow_copy_assignable, _Tp)...>::value)) { - __swallow(__tuple_leaf<_Indx, _Tp>::operator=(static_cast&>(__t).get())...); + _CUDA_VSTD::__swallow( + __tuple_leaf<_Indx, _Tp>::operator=(static_cast&>(__t).get())...); return *this; } _LIBCUDACXX_INLINE_VISIBILITY __tuple_impl& operator=(__tuple_impl&& __t) noexcept((__all<_LIBCUDACXX_TRAIT(is_nothrow_move_assignable, _Tp)...>::value)) { - __swallow(__tuple_leaf<_Indx, _Tp>::operator=( + _CUDA_VSTD::__swallow(__tuple_leaf<_Indx, _Tp>::operator=( _CUDA_VSTD::forward<_Tp>(static_cast<__tuple_leaf<_Indx, _Tp>&>(__t).get()))...); return *this; } @@ -520,7 +521,7 @@ struct _LIBCUDACXX_DECLSPEC_EMPTY_BASES __tuple_impl<__tuple_indices<_Indx...>, _LIBCUDACXX_INLINE_VISIBILITY void swap(__tuple_impl& __t) noexcept(__all<__is_nothrow_swappable<_Tp>::value...>::value) { - __swallow(__tuple_leaf<_Indx, _Tp>::swap(static_cast<__tuple_leaf<_Indx, _Tp>&>(__t))...); + _CUDA_VSTD::__swallow(__tuple_leaf<_Indx, _Tp>::swap(static_cast<__tuple_leaf<_Indx, _Tp>&>(__t))...); } };