Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Add tentative implementation of CommTest ex(C) pseudocode
[simgrid.git] / src / mc / explo / udpor / Unfolding.hpp
index e3c05c0ff6cf006f28548df253049603c723c2c9..3fa80f219dc2ed825bf660da47205004d87ee3e8 100644 (file)
@@ -28,8 +28,17 @@ public:
   size_t size() const { return this->event_handles.size(); }
   bool empty() const { return this->event_handles.empty(); }
 
-  void remove(const UnfoldingEvent* e);
-  void remove(const EventSet& events);
+  /**
+   * @brief Moves an event from UDPOR's global set `U` to
+   * the global set `G`
+   */
+  void mark_finished(const UnfoldingEvent* e);
+
+  /**
+   * @brief Moves all events in a set from UDPOR's global
+   * set `U` to the global set `G`
+   */
+  void mark_finished(const EventSet& events);
 
   /// @brief Adds a new event `e` to the Unfolding if that
   /// event is not equivalent to any of those already contained
@@ -64,7 +73,7 @@ public:
    * to an equivalent event that was already noted by the unfolding
    * at some point in the past
    */
-  template <typename... Args> const UnfoldingEvent* discover_event(Args... args)
+  template <typename... Args> const UnfoldingEvent* discover_event(Args&&... args)
   {
     auto candidate_event = std::make_unique<UnfoldingEvent>(std::forward<Args>(args)...);
     return insert(std::move(candidate_event));