message: Test that backend is CUDA before using CUDA-specifics in temporary_allocator.
  To handle the case that we are using nvcc to compile non-CUDA, e.g.
  OMP, code, test that the backend THRUST_DEVICE_SYSTEM is
  THRUST_DEVICE_SYSTEM_CUDA before including and using CUDA-specific
  code, terminate_with_message().
diff: #include <thrust/system/detail/bad_alloc.h>
  #include <cassert>
  -#ifdef __CUDACC__
  +#if defined(__CUDA_ARCH__) && THRUST_DEVICE_SYSTEM == THRUST_DEVICE_SYSTEM_CUDA
  #include <thrust/system/cuda/detail/terminate.h>
  #endif
  