fix: revert all unrelated upstream develop changes from phase-7 PR

Reverts 259 files that carried unrelated upstream changes through the
phase-6 merge: enum class removals (cppcoreguidelines-use-enum-class),
scoped_lock→lock_guard conversions (modernize-use-scoped-lock),
nodestore Backend API changes (void const* key), .clang-tidy config,
test infrastructure deletions, and miscellaneous develop changes.

These changes belong on develop, not in the telemetry PR chain.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Pratik Mankawde
2026-04-30 16:59:24 +01:00
parent f44b89b99d
commit f4555c80fe
261 changed files with 4172 additions and 1770 deletions

View File

@@ -27,7 +27,7 @@ using int128_t = __int128_t;
namespace xrpl {
thread_local Number::rounding_mode Number::mode_ = Number::to_nearest;
thread_local Number::rounding_mode Number::mode_ = Number::rounding_mode::to_nearest;
thread_local std::reference_wrapper<MantissaRange const> Number::range_ = largeRange;
Number::rounding_mode
@@ -51,9 +51,10 @@ Number::getMantissaScale()
void
Number::setMantissaScale(MantissaRange::mantissa_scale scale)
{
if (scale != MantissaRange::small && scale != MantissaRange::large)
if (scale != MantissaRange::mantissa_scale::small &&
scale != MantissaRange::mantissa_scale::large)
LogicError("Unknown mantissa scale");
range_ = scale == MantissaRange::small ? smallRange : largeRange;
range_ = scale == MantissaRange::mantissa_scale::small ? smallRange : largeRange;
}
// Guard
@@ -176,10 +177,10 @@ Number::Guard::round() const noexcept
{
auto mode = Number::getround();
if (mode == towards_zero)
if (mode == rounding_mode::towards_zero)
return -1;
if (mode == downward)
if (mode == rounding_mode::downward)
{
if (sbit_)
{
@@ -189,7 +190,7 @@ Number::Guard::round() const noexcept
return -1;
}
if (mode == upward)
if (mode == rounding_mode::upward)
{
if (sbit_)
return -1;
@@ -729,7 +730,7 @@ Number::operator/=(Number const& y)
// f can be up to 10^(38-19) = 10^19 safely
static_assert(smallRange.log == 15);
static_assert(largeRange.log == 18);
bool const small = Number::getMantissaScale() == MantissaRange::small;
bool const small = Number::getMantissaScale() == MantissaRange::mantissa_scale::small;
uint128_t const f = small ? 100'000'000'000'000'000 : 10'000'000'000'000'000'000ULL;
XRPL_ASSERT_PARTS(f >= minMantissa * 10, "Number::operator/=", "factor expected size");