From 4ba60eae2124e767daab3c2c9c8aa91df7f27385 Mon Sep 17 00:00:00 2001 From: Bart <11445373+bthomee@users.noreply.github.com> Date: Mon, 11 May 2026 09:45:01 -0400 Subject: [PATCH] Review feedback --- include/xrpl/shamap/SHAMap.h | 1 + include/xrpl/shamap/detail/TaggedPointer.ipp | 6 ++++-- src/test/core/Config_test.cpp | 1 + 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/include/xrpl/shamap/SHAMap.h b/include/xrpl/shamap/SHAMap.h index edb733410d..469ba2aa49 100644 --- a/include/xrpl/shamap/SHAMap.h +++ b/include/xrpl/shamap/SHAMap.h @@ -84,6 +84,7 @@ struct SHAMapNodeData Blob data; bool isLeaf; + // TODO: This constructor can be removed once we have fully switched to C++20 or beyond. SHAMapNodeData(SHAMapNodeID const& id, Blob d, bool leaf) : nodeID(id), data(std::move(d)), isLeaf(leaf) { diff --git a/include/xrpl/shamap/detail/TaggedPointer.ipp b/include/xrpl/shamap/detail/TaggedPointer.ipp index a39d9868d8..54b89fc72b 100644 --- a/include/xrpl/shamap/detail/TaggedPointer.ipp +++ b/include/xrpl/shamap/detail/TaggedPointer.ipp @@ -431,8 +431,10 @@ inline TaggedPointer::TaggedPointer( // allocate hashes and children, but do not run constructors TaggedPointer newHashesAndChildren{RawAllocateTag{}, toAllocate}; - SHAMapHash *newHashes = nullptr, *oldHashes = nullptr; - SHAMapTreeNodePtr *newChildren = nullptr, *oldChildren = nullptr; + SHAMapHash* newHashes = nullptr; + SHAMapHash* oldHashes = nullptr; + SHAMapTreeNodePtr* newChildren = nullptr; + SHAMapTreeNodePtr* oldChildren = nullptr; std::uint8_t newNumAllocated = 0; // structured bindings can't be captured in c++ 17; use tie instead std::tie(newNumAllocated, newHashes, newChildren) = newHashesAndChildren.getHashesAndChildren(); diff --git a/src/test/core/Config_test.cpp b/src/test/core/Config_test.cpp index e023e414a0..95f277212d 100644 --- a/src/test/core/Config_test.cpp +++ b/src/test/core/Config_test.cpp @@ -7,6 +7,7 @@ #include #include #include +#include // IWYU pragma: keep #include #include