diff --git a/include/eigenpy/deprecation-policy.hpp b/include/eigenpy/deprecation-policy.hpp index 061cd8012b49563b8b347c49eb0fe4f1d88575ef..85dc0096804bbbac609c4cd8085d7e7468846a37 100644 --- a/include/eigenpy/deprecation-policy.hpp +++ b/include/eigenpy/deprecation-policy.hpp @@ -19,6 +19,8 @@ constexpr PyObject *deprecationTypeToPyObj(DeprecationType dep) { return PyExc_DeprecationWarning; case DeprecationType::FUTURE: return PyExc_FutureWarning; + default: // The switch handles all cases explicitly, this should never be triggered. + throw std::invalid_argument("Undefined DeprecationType - this should never be triggered."); } }