From 510ea77f511591c21735b013e0d857599e9d6870 Mon Sep 17 00:00:00 2001 From: Frederic Suter Date: Sun, 9 Feb 2020 15:31:20 +0100 Subject: [PATCH] do not enforce a specific order --- src/s4u/s4u_Host.cpp | 6 ------ 1 file changed, 6 deletions(-) diff --git a/src/s4u/s4u_Host.cpp b/src/s4u/s4u_Host.cpp index b52da40fc2..b66f81abbf 100644 --- a/src/s4u/s4u_Host.cpp +++ b/src/s4u/s4u_Host.cpp @@ -318,12 +318,6 @@ sg_host_t* sg_host_list() xbt_assert(host_count > 0, "There is no host!"); std::vector hosts = e->get_all_hosts(); - auto last = std::remove_if(begin(hosts), end(hosts), [](const simgrid::s4u::Host* host) { - return not host || not host->get_netpoint() || not host->get_netpoint()->is_host(); - }); - std::sort(begin(hosts), last, - [](const simgrid::s4u::Host* a, const simgrid::s4u::Host* b) { return a->get_name() < b->get_name(); }); - sg_host_t* res = xbt_new(sg_host_t, hosts.size()); memcpy(res, hosts.data(), sizeof(sg_host_t) * hosts.size()); -- 2.20.1