diff --git a/src/stdgpu/impl/iterator_detail.h b/src/stdgpu/impl/iterator_detail.h index 513d2e5fd..a8287cf9b 100644 --- a/src/stdgpu/impl/iterator_detail.h +++ b/src/stdgpu/impl/iterator_detail.h @@ -19,6 +19,7 @@ #include #include #include +#include #include namespace stdgpu @@ -392,6 +393,17 @@ THRUST_NAMESPACE_BEGIN namespace detail { +// thrust 3.1 (CUDA 13.1) refactored their internal type traits towards C++17 style +#if THRUST_MAJOR_VERSION >= 3 && THRUST_MINOR_VERSION >= 1 +template +inline constexpr bool is_proxy_reference_v> = true; + +template +inline constexpr bool is_proxy_reference_v> = true; + +template +inline constexpr bool is_proxy_reference_v> = true; +#else template struct is_proxy_reference> : public thrust::detail::true_type { @@ -406,6 +418,7 @@ template struct is_proxy_reference> : public thrust::detail::true_type { }; +#endif } // namespace detail THRUST_NAMESPACE_END