Files
clang-p2996/llvm/unittests/ADT/IListNodeBaseTest.cpp
Stephen Tozer c6ed8289b7 [ADT] Fix incorrect const parent ptr type in ilist (#96059)
Fixes issue reported in: https://github.com/llvm/llvm-project/pull/94224

The recent commit above added an ilist_parent<ParentTy> option, which
added a parent pointer to the ilist_node_base type for the list. The
const methods for returning that parent pointer however were incorrectly
implemented, returning `const ParentPtrTy`, which is equivalent to
`ParentTy * const` rather than `const ParentTy *`. This patch fixes this
by passing around `ParentTy` in ilist's internal logic rather than
`ParentPtrTy`, removing the ability to have a `void*` parent pointer but
cleanly fixing this error.
2024-06-19 19:52:40 +01:00

5.8 KiB