about summary refs log tree commit diff stats
path: root/src/include
diff options
context:
space:
mode:
authorChi-Kuan Chiu <105687635+devarajabc@users.noreply.github.com>2025-06-09 14:16:43 +0800
committerGitHub <noreply@github.com>2025-06-09 08:16:43 +0200
commitcaba957426f5a93a1e4d6db5a9894708b1ed71b8 (patch)
tree44d92980ab14d398516fcfb2967492f2271a8318 /src/include
parent873be3cf879e3635a996bcdc34b3e3a6c15969a0 (diff)
downloadbox64-caba957426f5a93a1e4d6db5a9894708b1ed71b8.tar.gz
box64-caba957426f5a93a1e4d6db5a9894708b1ed71b8.zip
Refine the naming scheme in rbtree (#2717)
Replaced all occurrences of `rb_get_righter` with `rb_get_rightmost` and
`rb_get_lefter` with `rb_get_leftmost` for improved semantic clarity.

Also updated related function declarations, definitions, and usage
across:
- rbtree.c
- rbtree.h
- custommem.c
- dynablock.c
- env.c
- box64context.c
Diffstat (limited to 'src/include')
-rw-r--r--src/include/rbtree.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/include/rbtree.h b/src/include/rbtree.h
index fe1de5ab..376eef45 100644
--- a/src/include/rbtree.h
+++ b/src/include/rbtree.h
@@ -274,7 +274,7 @@ int rb_set_64(rbtree_t* tree, uintptr_t start, uintptr_t end, uint64_t data);
 int rb_unset(rbtree_t* tree, uintptr_t start, uintptr_t end);
 
 /**
- * rb_get_righter() - Retrieves the start value of the right-most node in a red-black tree.
+ * rb_get_rightmost() - Retrieves the start value of the right-most node in a red-black tree.
  * @tree: Pointer to the red-black tree whose right-most node's start value is to be retrieved.
  *
  * This function traverses the red-black tree from the root to the right-most node, which is the node
@@ -304,17 +304,17 @@ uint64_t rb_inc(rbtree_t* tree, uintptr_t start, uintptr_t end);
  * Returns the new value for the node (or 0 if non-existant / removed)
  */
 
-uintptr_t rb_get_righter(rbtree_t* tree);
+uintptr_t rb_get_rightmost(rbtree_t* tree);
 
 /**
- * rb_get_lefter() - Retrieves the start value of the left-most node in a red-black tree.
+ * rb_get_leftmost() - Retrieves the start value of the left-most node in a red-black tree.
  * @tree: Pointer to the red-black tree whose left-most node's start value is to be retrieved.
  *
  * This function traverses the red-black tree from the root to the left-most node, which is the node
  * with the lowest key value in the tree. 
  * Return: The start value of the left-most node if the tree is not empty; otherwise, 0.
  */
-uintptr_t rb_get_lefter(rbtree_t* tree);
+uintptr_t rb_get_leftmost(rbtree_t* tree);
 
 /**
  * @brief Print a rbtree (for debugging purpose)