mirror of
https://github.com/pybind/pybind11.git
synced 2026-04-19 22:39:09 +00:00
Fix detail::obj_class_name() to work correctly for meta classes. (#4436)
* Fix `detail::obj_class_name()` to work correctly for meta classes. * Adjust expected name for PyPy
This commit is contained in:
committed by
GitHub
parent
60f02f5f66
commit
f12e098f1d
@@ -55,6 +55,8 @@ void bind_empty0(py::module_ &m) {
|
||||
} // namespace test_class
|
||||
|
||||
TEST_SUBMODULE(class_, m) {
|
||||
m.def("obj_class_name", [](py::handle obj) { return py::detail::obj_class_name(obj.ptr()); });
|
||||
|
||||
// test_instance
|
||||
struct NoConstructor {
|
||||
NoConstructor() = default;
|
||||
|
||||
Reference in New Issue
Block a user