mirror of
https://github.com/microsoft/GSL.git
synced 2024-11-03 17:56:43 -05:00
Update std::byte detection in gsl_byte for MSVC (#561)
* Only check that `_HAS_STD_BYTE` is defined to a non-zero value
This commit is contained in:
parent
4c5fdb541f
commit
166ea80f66
@ -30,15 +30,15 @@
|
|||||||
|
|
||||||
#ifndef GSL_USE_STD_BYTE
|
#ifndef GSL_USE_STD_BYTE
|
||||||
// this tests if we are under MSVC and the standard lib has std::byte and it is enabled
|
// this tests if we are under MSVC and the standard lib has std::byte and it is enabled
|
||||||
#if _MSC_VER >= 1911 && (!defined(_HAS_STD_BYTE) || _HAS_STD_BYTE)
|
#if defined(_HAS_STD_BYTE) && _HAS_STD_BYTE
|
||||||
|
|
||||||
#define GSL_USE_STD_BYTE 1
|
#define GSL_USE_STD_BYTE 1
|
||||||
|
|
||||||
#else // _MSC_VER >= 1911 && (!defined(_HAS_STD_BYTE) || _HAS_STD_BYTE)
|
#else // defined(_HAS_STD_BYTE) && _HAS_STD_BYTE
|
||||||
|
|
||||||
#define GSL_USE_STD_BYTE 0
|
#define GSL_USE_STD_BYTE 0
|
||||||
|
|
||||||
#endif // _MSC_VER >= 1911 && (!defined(_HAS_STD_BYTE) || _HAS_STD_BYTE)
|
#endif // defined(_HAS_STD_BYTE) && _HAS_STD_BYTE
|
||||||
#endif // GSL_USE_STD_BYTE
|
#endif // GSL_USE_STD_BYTE
|
||||||
|
|
||||||
#else // _MSC_VER
|
#else // _MSC_VER
|
||||||
|
1
tests/unittest-cpp
Submodule
1
tests/unittest-cpp
Submodule
@ -0,0 +1 @@
|
|||||||
|
Subproject commit dc6b90838014ab985bf3cd74ac17ad9d00e1fbcb
|
Loading…
Reference in New Issue
Block a user