Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
[S4U] Remove the const for now
authorChristian Heinrich <franz-christian.heinrich@inria.fr>
Thu, 12 Apr 2018 09:07:01 +0000 (11:07 +0200)
committerChristian Heinrich <franz-christian.heinrich@inria.fr>
Fri, 13 Apr 2018 08:28:14 +0000 (10:28 +0200)
Won't compile otherwise, because we need to move other functions
to be const as well and to return const values.

include/simgrid/s4u/Host.hpp
src/s4u/s4u_host.cpp

index 76eb900..eb1c8f9 100644 (file)
@@ -97,7 +97,7 @@ public:
   const char* getProperty(const char* key);
   void setProperty(std::string key, std::string value);
   void getProcesses(std::vector<ActorPtr> * list);
-  int get_actor_count() const;
+  int get_actor_count();
   double getPstateSpeed(int pstate_index);
   int getPstatesCount() const;
   void setPstate(int pstate_index);
index 7c18d22..78e9b73 100644 (file)
@@ -188,7 +188,7 @@ void Host::getProcesses(std::vector<ActorPtr>* list)
 
 /** @brief Returns how many actors have been launched on this host */
 // FIXME: Specify whether the user should expect only non-daemon actors here!
-int Host::get_actor_count() const
+int Host::get_actor_count()
 {
   return this->extension<simgrid::simix::Host>()->process_list.size();
 }