Skip to content

Commit

Permalink
Avoid including yvals.h when the compiler is not MSVC. (#2545)
Browse files Browse the repository at this point in the history
* Only include yvals when the compiler is MSVC

* Use the right check

---------

Co-authored-by: Michael Schellenberger Costa <[email protected]>
  • Loading branch information
wmaxey and miscco authored Oct 14, 2024
1 parent b651905 commit 09ed522
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libcudacxx/include/cuda/std/__cccl/assert.h
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
//! _CCCL_ASSERT_IMPL_HOST should never be used directly
#if defined(_CCCL_COMPILER_NVRTC) // There is no host standard library in nvrtc
# define _CCCL_ASSERT_IMPL_HOST(expression, message) ((void) 0)
#elif __has_include(<yvals_core.h>) // MSVC uses _STL_VERIFY from <yvals.h>
#elif __has_include(<yvals.h>) && defined(_CCCL_COMPILER_MSVC) // MSVC uses _STL_VERIFY from <yvals.h>
# include <yvals.h>
# define _CCCL_ASSERT_IMPL_HOST(expression, message) _STL_VERIFY(expression, message)
#else // ^^^ MSVC STL ^^^ / vvv !MSVC STL vvv
Expand Down

0 comments on commit 09ed522

Please sign in to comment.