Skip to content

Commit ddc2aaa

Browse files
style: pre-commit fixes
1 parent f91cdbe commit ddc2aaa

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

include/pybind11/functional.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ struct type_caster<std::function<Return(Args...)>> {
141141

142142
std::cout << "BEFORE " << std::endl;
143143
auto codeAttr
144-
= reinterpret_borrow<object> (PyObject_GetAttrString(src.ptr(), "__code__"));
144+
= reinterpret_borrow<object>(PyObject_GetAttrString(src.ptr(), "__code__"));
145145
assert((static_cast<bool>(codeAttr)
146146
== static_cast<bool>(PyObject_HasAttrString(src.ptr(), "__code__")))
147147
&& "ptr and "
@@ -152,16 +152,16 @@ struct type_caster<std::function<Return(Args...)>> {
152152
argCount = argCountFromFuncCode(codeAttr);
153153
} else {
154154
auto callAttr
155-
= reinterpret_borrow<object> (PyObject_GetAttrString(src.ptr(), "__call__"));
155+
= reinterpret_borrow<object>(PyObject_GetAttrString(src.ptr(), "__call__"));
156156
assert((static_cast<bool>(callAttr)
157157
== static_cast<bool>(PyObject_HasAttrString(src.ptr(), "__call__")))
158158
&& "ptr and "
159159
"HasAttrString "
160160
"inconsistent for __call__");
161161
if (static_cast<bool>(PyObject_HasAttrString(src.ptr(), "__call__"))) {
162162
std::cout << "__call__ exists" << std::endl;
163-
auto codeAttr2 = reinterpret_borrow<object> (PyObject_GetAttrString(
164-
callAttr.ptr(), "__code__"));
163+
auto codeAttr2 = reinterpret_borrow<object>(
164+
PyObject_GetAttrString(callAttr.ptr(), "__code__"));
165165
argCount = argCountFromFuncCode(codeAttr2)
166166
- 1; // we have to remove the self argument
167167
} else {

0 commit comments

Comments
 (0)