mirror of
https://github.com/pybind/pybind11.git
synced 2025-02-23 17:09:27 +00:00
Improve formatting
This commit is contained in:
parent
a6923626c0
commit
ff3185ea7d
@ -482,8 +482,8 @@ PYBIND11_NOINLINE std::string error_string(PyObject *type, PyObject *value, PyOb
|
|||||||
result += str(value).cast<std::string>();
|
result += str(value).cast<std::string>();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (trace) {
|
|
||||||
#if !defined(PYPY_VERSION)
|
#if !defined(PYPY_VERSION)
|
||||||
|
if (trace) {
|
||||||
auto *tb = (PyTracebackObject *) trace;
|
auto *tb = (PyTracebackObject *) trace;
|
||||||
|
|
||||||
// Get the deepest trace possible.
|
// Get the deepest trace possible.
|
||||||
@ -507,8 +507,8 @@ PYBIND11_NOINLINE std::string error_string(PyObject *type, PyObject *value, PyOb
|
|||||||
frame = frame->f_back;
|
frame = frame->f_back;
|
||||||
Py_DECREF(f_code);
|
Py_DECREF(f_code);
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
@ -520,6 +520,7 @@ PYBIND11_NOINLINE std::string error_string() {
|
|||||||
}
|
}
|
||||||
return error_string(scope.type, scope.value, scope.trace);
|
return error_string(scope.type, scope.value, scope.trace);
|
||||||
}
|
}
|
||||||
|
|
||||||
PYBIND11_NOINLINE handle get_object_handle(const void *ptr, const detail::type_info *type) {
|
PYBIND11_NOINLINE handle get_object_handle(const void *ptr, const detail::type_info *type) {
|
||||||
auto &instances = get_internals().registered_instances;
|
auto &instances = get_internals().registered_instances;
|
||||||
auto range = instances.equal_range(ptr);
|
auto range = instances.equal_range(ptr);
|
||||||
|
Loading…
Reference in New Issue
Block a user