+
+bool CommWaitTransition::reversible_race(const Transition* other) const
+{
+ switch (type_) {
+ case Type::COMM_WAIT:
+ // If the other event is a communication event, then we are not reversible; otherwise we are reversible.
+ return other->type_ != Transition::Type::COMM_ASYNC_SEND && other->type_ != Transition::Type::COMM_ASYNC_RECV;
+ default:
+ xbt_die("Unexpected transition type %s", to_c_str(type_));
+ }
+}
+
+CommTestTransition::CommTestTransition(aid_t issuer, int times_considered, unsigned comm_, aid_t sender_,
+ aid_t receiver_, unsigned mbox_)
+ : Transition(Type::COMM_TEST, issuer, times_considered)
+ , comm_(comm_)
+ , mbox_(mbox_)
+ , sender_(sender_)
+ , receiver_(receiver_)
+{
+}