Problem description
Not a pybind bug, it should be vs2022 bug

solution:
https://www.reddit.com/r/cpp_questions/comments/qpo93t/error_c2039_invalid_parameter_is_not_a_member_of/
in the pybind11.h , Insert this code after line 22 , it can fix the problem
#elif defined(_MSC_VER)
#include <corecrt.h>
Reproducible example code
No response