X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/ab9a2d2c7dca2b08750d70ef5769fc2c14350ab6..3ba5d4a966c2ac976b2b1656c52145f70189d108:/src/simix/smx_synchro_private.h diff --git a/src/simix/smx_synchro_private.h b/src/simix/smx_synchro_private.h index 8066b4384f..c263d25463 100644 --- a/src/simix/smx_synchro_private.h +++ b/src/simix/smx_synchro_private.h @@ -6,18 +6,18 @@ #ifndef SIMIX_SYNCHRO_PRIVATE_H #define SIMIX_SYNCHRO_PRIVATE_H -#include "simgrid/s4u/conditionVariable.hpp" +#include "simgrid/s4u/ConditionVariable.hpp" #include "xbt/swag.h" namespace simgrid { namespace simix { -class XBT_PUBLIC() Mutex { +class XBT_PUBLIC() MutexImpl { public: - Mutex(); - ~Mutex(); - Mutex(Mutex const&) = delete; - Mutex& operator=(Mutex const&) = delete; + MutexImpl(); + ~MutexImpl(); + MutexImpl(MutexImpl const&) = delete; + MutexImpl& operator=(MutexImpl const&) = delete; void lock(smx_actor_t issuer); bool try_lock(smx_actor_t issuer); @@ -29,14 +29,13 @@ public: xbt_swag_t sleeping = nullptr; // boost::intrusive_ptr support: - friend void intrusive_ptr_add_ref(Mutex* mutex) + friend void intrusive_ptr_add_ref(MutexImpl* mutex) { // Atomic operation! Do not split in two instructions! - auto previous = (mutex->refcount_)++; + XBT_ATTRIB_UNUSED auto previous = (mutex->refcount_)++; xbt_assert(previous != 0); - (void) previous; } - friend void intrusive_ptr_release(Mutex* mutex) + friend void intrusive_ptr_release(MutexImpl* mutex) { // Atomic operation! Do not split in two instructions! auto count = --(mutex->refcount_);