Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Make the Catch2-SimGrid integration available to more tests
[simgrid.git] / teshsuite / s4u / dependencies / dependencies.cpp
index f0f2ba658fae8778ced3cbb9fbe89ba48f650e6a..699f27c00e4e8d0efa8df6fc9f46d34dea1a584b 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2006-2021. The SimGrid Team. All rights reserved.          */
+/* Copyright (c) 2006-2022. The SimGrid Team. All rights reserved.          */
 
 /* This program is free software; you can redistribute it and/or modify it
  * under the terms of the license (GNU LGPL) which comes with this package. */
@@ -13,8 +13,8 @@ int main(int argc, char** argv)
   xbt_assert(argc > 1, "Usage: %s platform_file\n\nExample: %s two_clusters.xml", argv[0], argv[0]);
   e.load_platform(argv[1]);
 
-  simgrid::s4u::Activity::on_completion_cb([](simgrid::s4u::Activity& activity) {
-    const auto* exec = dynamic_cast<simgrid::s4u::Exec*>(&activity);
+  simgrid::s4u::Activity::on_completion_cb([](simgrid::s4u::Activity const& activity) {
+    const auto* exec = dynamic_cast<simgrid::s4u::Exec const*>(&activity);
     if (exec == nullptr) // Only Execs are concerned here
       return;
     XBT_INFO("Exec '%s' start time: %f, finish time: %f", exec->get_cname(), exec->get_start_time(),