forked from microsoft/GSL
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:
committed by
Neil MacIntosh
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
Submodule tests/unittest-cpp added at dc6b908380
Reference in New Issue
Block a user