diff -r 4103050978f1 -r efb01b140aa7 ext/pybind11/include/pybind11/common.h --- a/ext/pybind11/include/pybind11/common.h Tue Feb 21 18:52:39 2017 +0000 +++ b/ext/pybind11/include/pybind11/common.h Tue Feb 21 18:53:00 2017 +0000 @@ -558,7 +558,8 @@ struct nodelete { template void operator()(T*) { } }; // overload_cast requires variable templates: C++14 or MSVC 2015 Update 2 -#if defined(PYBIND11_CPP14) || _MSC_FULL_VER >= 190023918 +#if defined(PYBIND11_CPP14) || ( \ + defined(_MSC_FULL_VER) &&_MSC_FULL_VER >= 190023918) #define PYBIND11_OVERLOAD_CAST 1 NAMESPACE_BEGIN(detail) diff -r 4103050978f1 -r efb01b140aa7 ext/pybind11/include/pybind11/stl.h --- a/ext/pybind11/include/pybind11/stl.h Tue Feb 21 18:52:39 2017 +0000 +++ b/ext/pybind11/include/pybind11/stl.h Tue Feb 21 18:53:00 2017 +0000 @@ -246,7 +246,7 @@ PYBIND11_TYPE_CASTER(T, _("Optional[") + value_conv::name() + _("]")); }; -#if PYBIND11_HAS_OPTIONAL +#ifdef PYBIND11_HAS_OPTIONAL template struct type_caster> : public optional_caster> {}; @@ -254,7 +254,7 @@ : public void_caster {}; #endif -#if PYBIND11_HAS_EXP_OPTIONAL +#ifdef PYBIND11_HAS_EXP_OPTIONAL template struct type_caster> : public optional_caster> {};