From 7d20142520918afd0793f35c514c9ab26b54b654 Mon Sep 17 00:00:00 2001 From: khizmax Date: Sat, 12 Mar 2016 00:55:10 +0300 Subject: [PATCH] Improved docs --- cds/intrusive/lazy_list_rcu.h | 2 +- cds/intrusive/michael_list_rcu.h | 2 +- cds/intrusive/michael_set_rcu.h | 5 +++-- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/cds/intrusive/lazy_list_rcu.h b/cds/intrusive/lazy_list_rcu.h index 1981bc54..244e4286 100644 --- a/cds/intrusive/lazy_list_rcu.h +++ b/cds/intrusive/lazy_list_rcu.h @@ -352,7 +352,7 @@ namespace cds { namespace intrusive { //@endcond public: - ///@name Forward iterators (only for debugging purpose) + ///@name Forward iterators (thread-safe only under RCU lock) //@{ /// Forward iterator /** diff --git a/cds/intrusive/michael_list_rcu.h b/cds/intrusive/michael_list_rcu.h index ed21242b..b19cf84a 100644 --- a/cds/intrusive/michael_list_rcu.h +++ b/cds/intrusive/michael_list_rcu.h @@ -371,7 +371,7 @@ namespace cds { namespace intrusive { //@endcond public: - ///@name Forward iterators (only for debugging purpose) + ///@name Forward iterators (thread-safe only under RCU lock) //@{ /// Forward iterator /** diff --git a/cds/intrusive/michael_set_rcu.h b/cds/intrusive/michael_set_rcu.h index bda744f3..867191e7 100644 --- a/cds/intrusive/michael_set_rcu.h +++ b/cds/intrusive/michael_set_rcu.h @@ -156,7 +156,7 @@ namespace cds { namespace intrusive { //@endcond public: - ///@name Forward iterators (only for debugging purpose) + ///@name Forward iterators (thread-safe only under RCU lock) //@{ /// Forward iterator /** @@ -164,7 +164,8 @@ namespace cds { namespace intrusive { - it has no post-increment operator - it iterates items in unordered fashion - @warning Use this iterator on the concurrent container for debugging purpose only. + You may safely use iterators in multi-threaded environment only under RCU lock. + Otherwise, a crash is possible if another thread deletes the element the iterator points to. */ typedef michael_set::details::iterator< bucket_type, false > iterator; -- 2.34.1