diff options
author | Nikolas Klauser <nikolasklauser@berlin.de> | 2025-08-05 19:55:30 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-08-05 19:55:30 +0200 |
commit | bb3c060ca41455bc48e48ec51a66910c164b4345 (patch) | |
tree | 87df1a0b15a859a2f831c3360deb3c3cefef0161 | |
parent | 4882874ddc1017f2f1b9b11fb67065440b101701 (diff) | |
download | llvm-bb3c060ca41455bc48e48ec51a66910c164b4345.zip llvm-bb3c060ca41455bc48e48ec51a66910c164b4345.tar.gz llvm-bb3c060ca41455bc48e48ec51a66910c164b4345.tar.bz2 |
[libc++] Fix incorrect down-cast in __tree (#152181)
-rw-r--r-- | libcxx/include/__tree | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libcxx/include/__tree b/libcxx/include/__tree index 1b1bb53..6ca1a62 100644 --- a/libcxx/include/__tree +++ b/libcxx/include/__tree @@ -1445,8 +1445,8 @@ __tree<_Tp, _Compare, _Allocator>::__tree(const __tree& __t) *__root_ptr() = static_cast<__node_base_pointer>(__copy_construct_tree(__t.__root())); __root()->__parent_ = __end_node(); - __begin_node_ = static_cast<__end_node_pointer>(std::__tree_min(static_cast<__node_base_pointer>(__end_node()))); - __size_ = __t.size(); + __begin_node_ = static_cast<__end_node_pointer>(std::__tree_min(__end_node()->__left_)); + __size_ = __t.size(); } template <class _Tp, class _Compare, class _Allocator> |