Adding return_value_policy::move to permissible policies for unique_ptr returns.…

Adding return_value_policy::move to permissible policies for unique_ptr returns. New stats for all tests combined: 3 failed, 467 passed.
parent caaa7b51
......@@ -1565,7 +1565,8 @@ struct smart_holder_type_caster<std::unique_ptr<T, D>> : smart_holder_type_caste
static handle cast(std::unique_ptr<T, D> &&src, return_value_policy policy, handle parent) {
if (policy != return_value_policy::automatic
&& policy != return_value_policy::reference_internal) {
&& policy != return_value_policy::reference_internal
&& policy != return_value_policy::move) {
// IMPROVABLE: Error message.
throw cast_error("Invalid return_value_policy for unique_ptr.");
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment