Avoid is_trivially_copyable on VariantUnion

For some reason some versions of the CUDA compiler would return true for
`is_trivially_copyable` on a `VariantUnion` even when the types of the
union caused the copy constructor to get deleted.

Solve the problem by using `AllTriviallyCopyable` instead of directly
caling `is_trivially_copyable` on the union.
This commit is contained in:
Kenneth Moreland 2021-03-23 13:34:39 -06:00
parent cb60401a63
commit cad5dc7b71

@ -93,7 +93,7 @@ struct VariantTriviallyCopyable;
template <typename... Ts>
struct VariantTriviallyCopyable<vtkm::VTK_M_NAMESPACE::internal::Variant<Ts...>>
: vtkmstd::is_trivially_copyable<VariantUnion<Ts...>>
: AllTriviallyCopyable<Ts...>
{
};
@ -102,7 +102,7 @@ struct VariantTriviallyConstructible;
template <typename... Ts>
struct VariantTriviallyConstructible<vtkm::VTK_M_NAMESPACE::internal::Variant<Ts...>>
: vtkmstd::is_trivially_constructible<VariantUnion<Ts...>>
: AllTriviallyConstructible<Ts...>
{
};