From 8a973d484f8ce73efb321b2a097f40439cb6af7c Mon Sep 17 00:00:00 2001 From: "Ralf W. Grosse-Kunstleve" Date: Wed, 1 Nov 2023 07:08:55 -0700 Subject: [PATCH] Change `std::move` to `std::forward` as suggested by @iwanders. --- include/pybind11/detail/smart_holder_poc.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/pybind11/detail/smart_holder_poc.h b/include/pybind11/detail/smart_holder_poc.h index 91873ab34..658657dc5 100644 --- a/include/pybind11/detail/smart_holder_poc.h +++ b/include/pybind11/detail/smart_holder_poc.h @@ -112,7 +112,7 @@ guarded_delete make_guarded_builtin_delete(bool armed_flag) { template struct custom_deleter { D deleter; - explicit custom_deleter(D &&deleter) : deleter{std::move(deleter)} {} + explicit custom_deleter(D &&deleter) : deleter{std::forward(deleter)} {} void operator()(void *raw_ptr) { deleter(static_cast(raw_ptr)); } };