diff --git a/include/pybind11/detail/common.h b/include/pybind11/detail/common.h index 5374b5a2..18d537ba 100644 --- a/include/pybind11/detail/common.h +++ b/include/pybind11/detail/common.h @@ -1148,6 +1148,15 @@ struct format_descriptor::value>> { static std::string format() { return std::string(1, c); } }; +template +struct format_descriptor< + T, + detail::enable_if_t::value>> { + static constexpr const char c = 'O'; + static constexpr const char value[2] = {c, '\0'}; + static std::string format() { return std::string(1, c); } +}; + #if !defined(PYBIND11_CPP17) template