Skip to content

Commit

Permalink
remove useless ctor (#3989)
Browse files Browse the repository at this point in the history
  • Loading branch information
Skylion007 authored Jun 3, 2022
1 parent a05bc3d commit 42a41bf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include/pybind11/functional.h
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ struct type_caster<std::function<Return(Args...)>> {
Return operator()(Args... args) const {
gil_scoped_acquire acq;
// casts the returned object as a rvalue to the return type
return object(hfunc.f(std::forward<Args>(args)...)).template cast<Return>();
return hfunc.f(std::forward<Args>(args)...).template cast<Return>();
}
};

Expand Down

0 comments on commit 42a41bf

Please sign in to comment.