+
+ // boost::intrusive_ptr<ActivitySet> support:
+ friend void intrusive_ptr_add_ref(ActivitySet* as)
+ {
+ XBT_ATTRIB_UNUSED auto previous = as->refcount_.fetch_add(1);
+ xbt_assert(previous != 0);
+ }
+
+ friend void intrusive_ptr_release(ActivitySet* as)
+ {
+ if (as->refcount_.fetch_sub(1) == 1)
+ delete as;
+ }