From 0c7aec480a418a56ec986d0094cf1a90fced4d8e Mon Sep 17 00:00:00 2001 From: Jason Rhinelander Date: Fri, 15 Dec 2017 13:21:52 -0400 Subject: [PATCH] Simplify arg copying --- include/pybind11/pybind11.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/include/pybind11/pybind11.h b/include/pybind11/pybind11.h index 1a12ed0b5..5769509dd 100644 --- a/include/pybind11/pybind11.h +++ b/include/pybind11/pybind11.h @@ -588,8 +588,7 @@ protected: size_t args_size = n_args_in - args_copied; extra_args = tuple(args_size); for (size_t i = 0; i < args_size; ++i) { - handle item = PyTuple_GET_ITEM(args_in, args_copied + i); - extra_args[i] = reinterpret_borrow(item); + extra_args[i] = PyTuple_GET_ITEM(args_in, args_copied + i); } } call.args.push_back(extra_args);