mirror of
https://github.com/microsoft/GSL.git
synced 2025-03-20 04:27:51 -04:00
change macro test to use __cplusplus instead of __has_cpp_attribute
This commit is contained in:
parent
01eaf5bef1
commit
afe824490e
@ -32,11 +32,11 @@
|
||||
|
||||
#endif // _MSC_VER
|
||||
|
||||
#if __has_cpp_attribute(nodiscard) >= 201603L
|
||||
#if defined(__cplusplus) && (__cplusplus >= 201703L)
|
||||
#define GSL_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
#define GSL_NODISCARD
|
||||
#endif
|
||||
#endif // defined(__cplusplus) && (__cplusplus >= 201703L)
|
||||
|
||||
namespace gsl
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user