Changeset 993f5ac in rtems for cpukit/sapi


Ignore:
Timestamp:
Jul 23, 2014, 11:03:54 AM (5 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
4.11, master
Children:
0ef6e3bf
Parents:
4752550f
git-author:
Sebastian Huber <sebastian.huber@…> (07/23/14 11:03:54)
git-committer:
Sebastian Huber <sebastian.huber@…> (08/07/14 13:59:29)
Message:

rbtree: Simplify insert and extract

Simplify _RBTree_Insert() and _RBTree_Extract(). Remove more
superfluous NULL pointer checks. Change _RBTree_Is_root() to use only
the node. Add parent parameter to _RBTree_Sibling(). Delete
_RBTree_Grandparent() and _RBTree_Parent_sibling().

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpukit/sapi/include/rtems/rbtree.h

    r4752550f r993f5ac  
    196196
    197197/**
    198  * @brief Return pointer to the parent child node from this node.
    199  *
    200  * This function returns a pointer to the parent node of @a the_node.
     198 * @copydoc _RBTree_Parent()
    201199 */
    202200RTEMS_INLINE_ROUTINE rtems_rbtree_node *rtems_rbtree_parent(
     
    249247
    250248/**
    251  * @brief Is this node the RBTree root.
    252  *
    253  * This function returns true if @a the_node is the root of @a the_rbtree and
    254  * false otherwise.
     249 * @copydoc _RBTree_Is_root()
    255250 */
    256251RTEMS_INLINE_ROUTINE bool rtems_rbtree_is_root(
    257   const rtems_rbtree_control *the_rbtree,
    258   const rtems_rbtree_node *the_node
    259 )
    260 {
    261   return _RBTree_Is_root( the_rbtree, the_node );
     252  const rtems_rbtree_node *the_node
     253)
     254{
     255  return _RBTree_Is_root( the_node );
    262256}
    263257
Note: See TracChangeset for help on using the changeset viewer.