Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/share/man/man3 Clarify the usage, so hopefully nobody else m...



details:   https://anonhg.NetBSD.org/src/rev/808a70a1f51f
branches:  trunk
changeset: 347509:808a70a1f51f
user:      dholland <dholland%NetBSD.org@localhost>
date:      Mon Aug 29 03:50:05 2016 +0000

description:
Clarify the usage, so hopefully nobody else makes the set of wrong
assumptions I just did.

diffstat:

 share/man/man3/rbtree.3 |  17 +++++++++++++----
 1 files changed, 13 insertions(+), 4 deletions(-)

diffs (45 lines):

diff -r c20334128a74 -r 808a70a1f51f share/man/man3/rbtree.3
--- a/share/man/man3/rbtree.3   Mon Aug 29 03:31:59 2016 +0000
+++ b/share/man/man3/rbtree.3   Mon Aug 29 03:50:05 2016 +0000
@@ -1,4 +1,4 @@
-.\"     $NetBSD: rbtree.3,v 1.10 2014/03/18 18:20:39 riastradh Exp $
+.\"     $NetBSD: rbtree.3,v 1.11 2016/08/29 03:50:05 dholland Exp $
 .\"
 .\" Copyright (c) 2010 The NetBSD Foundation, Inc.
 .\" All rights reserved.
@@ -27,7 +27,7 @@
 .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 .\" POSSIBILITY OF SUCH DAMAGE.
 .\"
-.Dd March 13, 2013
+.Dd August 29, 2016
 .Dt RBTREE 3
 .Os
 .Sh NAME
@@ -118,8 +118,8 @@
 the operator for comparing a node in the tree with a key,
 the offset of member
 .Vt rb_node_t
-within a node,
-and the opaque context passed to the operators.
+within the node type,
+and the opaque context pointer passed to the comparison functions.
 Members of
 .Vt rb_tree_ops_t
 are
@@ -131,6 +131,15 @@
 .Ed
 .It Vt rb_node_t
 A node in a red-black tree has this structure as a member.
+The offset of the
+.Vt rb_node_t
+member in the caller's node structure should be provided as
+.Va rbto_node_offset .
+(None of the functions in the
+.Nm
+interface are meant to take pointers directly to the
+.Vt rb_node_t
+member.)
 .El
 .Sh FUNCTIONS
 .Bl -tag -width compact



Home | Main Index | Thread Index | Old Index