Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
add prog_ns3 to manifest
[simgrid.git] / src / mc / transition / TransitionAny.cpp
index 13351537264b2e82901c29b47d6c4a3916753677..4813a00ff8b0c230f05fe674729683188108ba3b 100644 (file)
@@ -1,23 +1,18 @@
-/* Copyright (c) 2015-2022. The SimGrid Team. All rights reserved.          */
+/* Copyright (c) 2015-2023. 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. */
 
 #include "src/mc/transition/TransitionAny.hpp"
+#include "simgrid/config.h"
 #include "xbt/asserts.h"
-#include <simgrid/config.h>
-#if SIMGRID_HAVE_MC
-#include "src/mc/ModelChecker.hpp"
-#include "src/mc/Session.hpp"
-#include "src/mc/api/State.hpp"
-#endif
+#include "xbt/string.hpp"
 
 #include <sstream>
 
 XBT_LOG_NEW_DEFAULT_SUBCATEGORY(mc_trans_any, mc_transition, "Logging specific to MC WaitAny / TestAny transitions");
 
-namespace simgrid {
-namespace mc {
+namespace simgrid::mc {
 
 TestAnyTransition::TestAnyTransition(aid_t issuer, int times_considered, std::stringstream& stream)
     : Transition(Type::TESTANY, issuer, times_considered)
@@ -32,10 +27,10 @@ TestAnyTransition::TestAnyTransition(aid_t issuer, int times_considered, std::st
 }
 std::string TestAnyTransition::to_string(bool verbose) const
 {
-  auto res = xbt::string_printf("%ld: TestAny{ ", aid_);
+  auto res = xbt::string_printf("TestAny{ ");
   for (auto const* t : transitions_)
     res += t->to_string(verbose);
-  res += "}";
+  res += " }";
   return res;
 }
 bool TestAnyTransition::depends(const Transition* other) const
@@ -54,10 +49,10 @@ WaitAnyTransition::WaitAnyTransition(aid_t issuer, int times_considered, std::st
 }
 std::string WaitAnyTransition::to_string(bool verbose) const
 {
-  auto res = xbt::string_printf("%ld: WaitAny{ ", aid_);
+  auto res = xbt::string_printf("WaitAny{ ");
   for (auto const* t : transitions_)
     res += t->to_string(verbose);
-  res += "}";
+  res += " }";
   return res;
 }
 bool WaitAnyTransition::depends(const Transition* other) const
@@ -65,5 +60,4 @@ bool WaitAnyTransition::depends(const Transition* other) const
   return transitions_[times_considered_]->depends(other);
 }
 
-} // namespace mc
-} // namespace simgrid
+} // namespace simgrid::mc