From: Martin Quinson Date: Thu, 8 Aug 2019 16:08:43 +0000 (+0200) Subject: shy attempt at simplifying the simcall mechanism X-Git-Tag: v3.24~210 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/bd11885138355943e56e13d03850740ea2bcabd7 shy attempt at simplifying the simcall mechanism --- diff --git a/include/simgrid/simix.hpp b/include/simgrid/simix.hpp index 9b48080f25..9662eb017d 100644 --- a/include/simgrid/simix.hpp +++ b/include/simgrid/simix.hpp @@ -29,17 +29,6 @@ XBT_PUBLIC void simcall_run_kernel(std::function const& code); */ XBT_PUBLIC void simcall_run_blocking(std::function const& code); -template inline -void simcall_run_kernel(F& f) -{ - simcall_run_kernel(std::function(std::ref(f))); -} -template inline -void simcall_run_blocking(F& f) -{ - simcall_run_blocking(std::function(std::ref(f))); -} - namespace simgrid { namespace simix { diff --git a/include/xbt/future.hpp b/include/xbt/future.hpp index 31870ce502..4d2842fca0 100644 --- a/include/xbt/future.hpp +++ b/include/xbt/future.hpp @@ -127,7 +127,7 @@ template auto fulfill_promise(R& promise, F&& code) -> declty } } -template auto fulfill_promise(P& promise, F&& code) -> decltype(promise.set_value()) +template auto fulfill_promise(R& promise, F&& code) -> decltype(promise.set_value()) { try { std::forward(code)();