future-proof Python version check from commit 31680e6 (@lgritz)

This commit is contained in:
Wenzel Jakob 2019-09-21 18:09:35 +02:00
parent 82cf793588
commit f3109d8419
1 changed files with 1 additions and 1 deletions

View File

@ -1566,7 +1566,7 @@ public:
#if PY_MAJOR_VERSION < 3
def("__long__", [](Type value) { return (Scalar) value; });
#endif
#if PY_MAJOR_VERSION >= 3 && PY_MINOR_VERSION >= 8
#if PY_MAJOR_VERSION > 3 || (PY_MAJOR_VERSION == 3 && PY_MINOR_VERSION >= 8)
def("__index__", [](Type value) { return (Scalar) value; });
#endif