From 1be06aad4d9b3ce58b9893917714f87cb19c766c Mon Sep 17 00:00:00 2001 From: Arnaud Giersch Date: Fri, 17 May 2019 10:33:34 +0200 Subject: [PATCH] Return const& for consistency. --- include/simgrid/s4u/Exec.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/simgrid/s4u/Exec.hpp b/include/simgrid/s4u/Exec.hpp index d1c62eff20..d02f57eef8 100644 --- a/include/simgrid/s4u/Exec.hpp +++ b/include/simgrid/s4u/Exec.hpp @@ -66,7 +66,7 @@ public: ExecPtr set_tracing_category(const std::string& category); ExecPtr set_timeout(double timeout); Exec* cancel() override; - std::string get_name() const { return name_; } + const std::string& get_name() const { return name_; } const char* get_cname() const { return name_.c_str(); } XBT_ATTRIB_DEPRECATED_v324("Please use Exec::wait_for()") void wait(double t) override { wait_for(t); } -- 2.20.1