Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Make single argument constructor LinkInRoute::LinkInRoute(const Link*) explicit.
[simgrid.git] / examples / cpp / network-factors / s4u-network-factors.cpp
index 922f0b4..3f8598e 100644 (file)
@@ -78,12 +78,10 @@ static void load_platform()
     const sg4::Link* l = root->create_split_duplex_link(hostname, BW_REMOTE)->set_latency(LATENCY)->seal();
 
     /* add link UP/DOWN for communications from the host */
-    root->add_route(host->get_netpoint(), nullptr, nullptr, nullptr,
-                    std::vector<sg4::LinkInRoute>{{l, sg4::LinkInRoute::Direction::UP}}, true);
+    root->add_route(host->get_netpoint(), nullptr, nullptr, nullptr, {{l, sg4::LinkInRoute::Direction::UP}}, true);
 
     const sg4::Link* loopback = root->create_link(hostname + "_loopback", BW_LOCAL)->set_latency(LATENCY)->seal();
-    root->add_route(host->get_netpoint(), host->get_netpoint(), nullptr, nullptr,
-                    std::vector<sg4::LinkInRoute>{loopback});
+    root->add_route(host->get_netpoint(), host->get_netpoint(), nullptr, nullptr, {sg4::LinkInRoute(loopback)});
   }
 
   root->seal();