From 4a7bdcc10de06b475a9d52ca1567485e5718eace Mon Sep 17 00:00:00 2001 From: David Robillard Date: Fri, 6 Oct 2017 12:12:42 +0200 Subject: Allow use of make_managed with move-only arguments --- raul/Maid.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'raul') diff --git a/raul/Maid.hpp b/raul/Maid.hpp index 29b6473..1bd40a5 100644 --- a/raul/Maid.hpp +++ b/raul/Maid.hpp @@ -116,7 +116,7 @@ public: /** Make a unique_ptr that will dispose its object when dropped. */ template managed_ptr make_managed(Args&&... args) { - T* obj = new T(args...); + T* obj = new T(std::forward(args)...); return std::unique_ptr >(obj, Disposer(*this)); } -- cgit v1.2.1