67-uninitialized-algorithms.patch 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. diff --git a/include/__memory/uninitialized_algorithms.h b/include/__memory/uninitialized_algorithms.h
  2. index 2b68df8..058ff46 100644
  3. --- a/include/__memory/uninitialized_algorithms.h
  4. +++ b/include/__memory/uninitialized_algorithms.h
  5. @@ -566,6 +566,7 @@ struct __allocator_has_trivial_copy_construct : _Not<__has_construct<_Alloc, _Ty
  6. template <class _Type>
  7. struct __allocator_has_trivial_copy_construct<allocator<_Type>, _Type> : true_type {};
  8. +#ifndef __CUDACC__
  9. template <class _Alloc,
  10. class _In,
  11. class _RawTypeIn = __remove_const_t<_In>,
  12. @@ -589,6 +590,7 @@ __uninitialized_allocator_copy_impl(_Alloc&, _In* __first1, _In* __last1, _Out*
  13. return std::copy(__first1, __last1, const_cast<_RawTypeIn*>(__first2));
  14. }
  15. }
  16. +#endif // __CUDACC__
  17. template <class _Alloc, class _Iter1, class _Sent1, class _Iter2>
  18. _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX20 _Iter2 __uninitialized_allocator_copy(_Alloc& __alloc, _Iter1 __first1, _Sent1 __last1, _Iter2 __first2) {
  19. @@ -629,7 +631,7 @@ struct __allocator_has_trivial_move_construct : _Not<__has_construct<_Alloc, _Ty
  20. template <class _Type>
  21. struct __allocator_has_trivial_move_construct<allocator<_Type>, _Type> : true_type {};
  22. -#ifndef _LIBCPP_COMPILER_GCC
  23. +#if !defined(_LIBCPP_COMPILER_GCC) && !defined(__CUDACC__)
  24. template <
  25. class _Alloc,
  26. class _Iter1,
  27. @@ -650,7 +652,7 @@ __uninitialized_allocator_move_if_noexcept(_Alloc&, _Iter1 __first1, _Iter1 __la
  28. return std::move(__first1, __last1, __first2);
  29. }
  30. }
  31. -#endif // _LIBCPP_COMPILER_GCC
  32. +#endif // !defined(_LIBCPP_COMPILER_GCC) && !defined(__CUDACC__)
  33. _LIBCPP_END_NAMESPACE_STD