mirror of
https://github.com/RYDE-WORK/pybind11.git
synced 2026-02-05 06:53:36 +08:00
Only enable std::optional if compiling in >= C++14 (#476)
This commit is contained in:
parent
44a69f78cf
commit
12edaaa66a
@ -22,7 +22,7 @@
|
|||||||
#pragma warning(disable: 4127) // warning C4127: Conditional expression is constant
|
#pragma warning(disable: 4127) // warning C4127: Conditional expression is constant
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef __has_include
|
#if defined(PYBIND11_CPP14) && defined(__has_include)
|
||||||
// std::optional
|
// std::optional
|
||||||
# if __has_include(<optional>)
|
# if __has_include(<optional>)
|
||||||
# include <optional>
|
# include <optional>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user