[PATCH] D154417: [libc++] Disable tree invariant check in asserts mode

Louis Dionne via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Jul 4 11:58:39 PDT 2023


ldionne added a comment.

LGTM, but as a matter of process, please try to wait for someone from the libc++ review group before submitting. Thanks for the fix!



================
Comment at: libcxx/include/__tree:379-380
     _LIBCPP_ASSERT_UNCATEGORIZED(__z != nullptr, "The node to remove should not be null");
-    _LIBCPP_ASSERT_UNCATEGORIZED(std::__tree_invariant(__root), "The tree invariants should hold");
+    // TODO: Use in the new debug mode:
+    // _LIBCPP_DEBUG_ASSERT(std::__tree_invariant(__root), "The tree invariants should hold");
     // __z will be removed from the tree.  Client still needs to destruct/deallocate it
----------------
CC @var-const in case you want to annotate your TODOs for the debug mode in some special way to find them later.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D154417/new/

https://reviews.llvm.org/D154417



More information about the cfe-commits mailing list