Fix macro-redefinition issue with MSVC+CUDA

Closes #2603
This commit is contained in:
Martin Hořeňovský 2023-01-15 00:24:37 +01:00
parent 3486f8ed9e
commit e27bb7198d

View File

@ -181,8 +181,14 @@
// Visual C++
#if defined(_MSC_VER)
# define CATCH_INTERNAL_START_WARNINGS_SUPPRESSION __pragma( warning(push) )
# define CATCH_INTERNAL_STOP_WARNINGS_SUPPRESSION __pragma( warning(pop) )
// We want to defer to nvcc-specific warning suppression if we are compiled
// with nvcc masquerading for MSVC.
# if !defined( __CUDACC__ )
# define CATCH_INTERNAL_START_WARNINGS_SUPPRESSION \
__pragma( warning( push ) )
# define CATCH_INTERNAL_STOP_WARNINGS_SUPPRESSION \
__pragma( warning( pop ) )
# endif
// Universal Windows platform does not support SEH
// Or console colours (or console at all...)