From 6287c14ec0b01d759a8d50da1e7cee38c67f525d Mon Sep 17 00:00:00 2001 From: Arnaud Giersch Date: Wed, 3 Jul 2019 14:31:35 +0200 Subject: [PATCH] [sonar] Replace "std::function" by a template parameter. --- src/smpi/internals/smpi_global.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/smpi/internals/smpi_global.cpp b/src/smpi/internals/smpi_global.cpp index c7ab73e5bc..0b497fb09f 100644 --- a/src/smpi/internals/smpi_global.cpp +++ b/src/smpi/internals/smpi_global.cpp @@ -421,8 +421,8 @@ typedef std::function smpi_entry_point_type; typedef int (* smpi_c_entry_point_type)(int argc, char **argv); typedef void (*smpi_fortran_entry_point_type)(); -static int smpi_run_entry_point(const smpi_entry_point_type& entry_point, const std::string& executable_path, - std::vector args) +template +static int smpi_run_entry_point(const F& entry_point, const std::string& executable_path, std::vector args) { // copy C strings, we need them writable std::vector* args4argv = new std::vector(args.size()); -- 2.20.1