Ed Hennis
1bb1d71565
test: Add more Number edge case tests, showing failures
...
- NumberAddDirectedSignWrong
- Addition of two negative numbers with the same exponent rounds
ToNearest in the wrong direction.
- Also include unit test cases with same exponent, and mixed signs.
- No rounding issues in any combination, because the exponent can't
change.
- NumberAddToNearestPicksFarther
- In scenarios where the two operands have different signs, and
significantly different exponents, you can end up in a situation
where the rounding looks like 0.5, which may round down to even, but
is actually 0.5....nnn, which should always round up, you get the
wrong result.
2026-06-11 18:27:25 -04:00
Ed Hennis
902fbdc3ad
Also fix local 3_2_0 variable names
2026-06-09 19:06:38 -04:00
Ed Hennis
48d1c70b6c
Future proofing: Rename Large and Enabled to Large330 and Enabled330
...
- If more fixes need to be made in the future, they can be added after,
instead of needing to do the "rename dance", I had to do with this PR.
2026-06-09 18:44:46 -04:00
Ed Hennis
66ff72f56d
clang-tidy: rename MantissaScale enums from "3_2_0" to "320"
2026-06-09 18:38:03 -04:00
Ed Hennis
63f1a40b77
Clean up the "New" names
2026-06-09 17:06:27 -04:00
Ed Hennis
5bafceefaf
Merge remote-tracking branch 'XRPLF/develop' into ximinez/number-round-maxrep-down
...
* XRPLF/develop:
fix: Fix Number comparison operator (7406)
feat: Use C++ 23 standard (7431)
refactor: Introduce XRPL_ASSERT_IF for amendment-gated assertions (7378)
2026-06-09 16:51:38 -04:00
Ed Hennis
44f3011b9b
Merge remote-tracking branch 'XRPLF/develop' into ximinez/number-round-maxrep-down
...
* XRPLF/develop:
refactor: Change config section and key string literals into constants (7095)
refactor: Use `std::move` and `std::string_view` where possible (7424)
refactor: Use const function arguments where possible (7423)
ci: Use XRPLF/actions build-multiarch-image workflow (7428)
ci: Use new packaging images and don't cancel develop builds (7417)
ci: [DEPENDABOT] bump codecov/codecov-action from 6.0.1 to 7.0.0 (7426)
2026-06-09 16:45:02 -04:00
Ed Hennis
d9c63cb9bc
Update to use a new amendment, since this PR will not be part of 3.2.0
...
- This requires creating yet another MantissaScale, and CuspRoundingFix
option.
2026-06-09 16:44:13 -04:00
Ed Hennis
2cbc3c139e
fix: Fix Number comparison operator ( #7406 )
2026-06-09 17:46:56 +00:00
Ayaz Salikhov
fccb109e48
feat: Use C++ 23 standard ( #7431 )
2026-06-09 17:36:17 +00:00
Vito Tumas
0fb1aca461
refactor: Introduce XRPL_ASSERT_IF for amendment-gated assertions ( #7378 )
...
Co-authored-by: xrplf-ai-reviewer[bot] <266832837+xrplf-ai-reviewer[bot]@users.noreply.github.com>
2026-06-09 17:02:06 +00:00
Bart
c552eb333f
refactor: Change config section and key string literals into constants ( #7095 )
...
Co-authored-by: Bart <11445373+bthomee@users.noreply.github.com >
2026-06-09 14:58:21 +00:00
Bart
c9769d1add
refactor: Use std::move and std::string_view where possible ( #7424 )
...
Co-authored-by: Bart <11445373+bthomee@users.noreply.github.com >
2026-06-09 13:56:32 +00:00
Bart
ee9fbc4e08
refactor: Use const function arguments where possible ( #7423 )
...
Co-authored-by: Bart <11445373+bthomee@users.noreply.github.com >
2026-06-09 10:04:09 +00:00
Ed Hennis
5bccfe2b6d
clang-tidy: Guard public member variable names; Missing include
2026-06-08 19:03:53 -04:00
Ed Hennis
308e46d0da
Clean up tests
2026-06-08 19:00:24 -04:00
Ayaz Salikhov
577d7457f1
ci: Use XRPLF/actions build-multiarch-image workflow ( #7428 )
2026-06-08 17:10:05 +00:00
Ayaz Salikhov
a389f922dd
ci: Use new packaging images and don't cancel develop builds ( #7417 )
...
Co-authored-by: Bart <bthomee@users.noreply.github.com >
2026-06-08 13:41:08 +00:00
dependabot[bot]
79f4ddc4a6
ci: [DEPENDABOT] bump codecov/codecov-action from 6.0.1 to 7.0.0 ( #7426 )
...
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-06-08 09:37:50 +00:00
Ed Hennis
fe64b99147
Reorganize the subtraction tests
2026-06-06 16:20:51 -04:00
Ed Hennis
d7ce0e2dd3
Fix formatting, add an assert
2026-06-06 15:38:29 -04:00
Ed Hennis
c165af497e
Revert "Rollback Number class changes; show the fix works without side effects"
...
This reverts commit 8743be8eae .
2026-06-06 14:35:35 -04:00
Ed Hennis
8743be8eae
Rollback Number class changes; show the fix works without side effects
2026-06-06 14:34:31 -04:00
Ed Hennis
3a5c85067a
Include rounding in failed unit tests
2026-06-06 14:33:31 -04:00
Ed Hennis
2f701121b4
Merge remote-tracking branch 'upstream/develop' into ximinez/number-round-maxrep-down
...
* upstream/develop:
build: Create single test binary xrpl_tests (7327)
ci: [DEPENDABOT] bump actions/checkout from 6.0.2 to 6.0.3 (7414)
ci: Refactor build-related nix / docker / workflows (7408)
ci: Use multiple directories in dependabot config (7413)
ci: Update clang-tidy to nix-based v22 (7412)
2026-06-06 14:04:24 -04:00
Ed Hennis
961ac6671e
Improve comment descriptions
2026-06-06 13:09:52 -04:00
Ed Hennis
012c67a7eb
Rework subtraction rounding (again) for more accuracy
...
- Go back to the old method of computing the mantissa, but when post
processing, expand the mantissa to slightly larger than maxMantissa,
then in doRoundDown, if the result is not exact, subtract one.
Finally, let doNormalize figure out the rounding of the result.
2026-06-06 01:04:26 -04:00
Ayaz Salikhov
949887feb9
build: Create single test binary xrpl_tests ( #7327 )
2026-06-05 19:24:32 +00:00
dependabot[bot]
fc57dab78b
ci: [DEPENDABOT] bump actions/checkout from 6.0.2 to 6.0.3 ( #7414 )
...
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-06-05 17:17:47 +00:00
Ayaz Salikhov
63ffdc39dc
ci: Refactor build-related nix / docker / workflows ( #7408 )
2026-06-05 17:05:19 +00:00
Ed Hennis
74c66d0944
refactor: Construct Number::Guard from MantissaRange or relevant fields
...
- Simplifies the function signatures in Guard, because it doesn't need
to have those values passed in constantly.
- Also simplifies some of the functions because they don't need to store
values just to pass them to Guard functions.
2026-06-05 12:06:41 -04:00
Ayaz Salikhov
6571f75d39
ci: Use multiple directories in dependabot config ( #7413 )
2026-06-05 14:36:05 +00:00
Ayaz Salikhov
2111bb4b95
ci: Update clang-tidy to nix-based v22 ( #7412 )
2026-06-05 14:11:47 +00:00
Ed Hennis
f1bb4ded21
clang-tidy: template param names, const correctness, braces
2026-06-04 20:05:53 -04:00
Ed Hennis
aa8888732e
Merge branch 'develop' into ximinez/number-round-maxrep-down
2026-06-04 19:03:32 -04:00
Ayaz Salikhov
8abe82eefa
ci: Redesign matrix configuration based on Nix images ( #7385 )
...
Co-authored-by: semgrep-companion-app[bot] <218312740+semgrep-companion-app[bot]@users.noreply.github.com>
2026-06-04 20:02:59 +00:00
Ayaz Salikhov
5b8e6cd1dd
test: Fix LCOV_EXCL_END -> LCOV_EXCL_STOP ( #7407 )
2026-06-04 19:35:36 +00:00
Ayaz Salikhov
12e81abef3
ci: Improve sanitizer-libs, add doxygen, dpkg, rpm in nix ( #7403 )
2026-06-04 14:52:42 +00:00
Ayaz Salikhov
6c543426c3
ci: Fix clang asan include dirs in nix images, add curl & gnupg ( #7400 )
2026-06-03 22:19:15 +00:00
yinyiqian1
e5cf1a0985
fix: Add zero NFT Offer ID check for NFTokenCancelOffer ( #7391 )
2026-06-03 19:30:20 +00:00
Ayaz Salikhov
023bdaeeed
ci: Install gcov, nettools, cacert in nix images ( #7398 )
2026-06-03 19:14:17 +00:00
Bart
96b2c0964f
refactor: Replace intr_ptr::SharedPtr<SHAMapTreeNode> by SHAMapTreeNodePtr ( #7396 )
...
Co-authored-by: Bart <11445373+bthomee@users.noreply.github.com >
2026-06-03 15:34:19 +00:00
Ayaz Salikhov
1441d4690d
chore: Update flake.lock to allow conan with clang-22 support ( #7390 )
2026-06-03 00:16:02 +00:00
Ed Hennis
c84939ccea
Remove the kMaxRep+1 rounding tests
2026-06-02 15:59:26 -04:00
Ed Hennis
9e8c3caef4
Improve accuracy of Number::operator+=
...
- Use more of the available range of the uint128 operands.
- Also refactor Number::Guard::round() to return an enum.
2026-06-02 15:35:42 -04:00
Vito Tumas
225ed204ad
test: Suppress invariant-failure logs in Vault and LoanBroker bug-regression tests ( #7379 )
2026-06-02 17:12:09 +00:00
Ayaz Salikhov
ad111bcc22
ci: Patch binaries in nix-based images and test in every distro ( #7376 )
...
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com >
2026-06-02 13:51:20 +00:00
Ed Hennis
35bee87909
Experimental: Scale addition operands up to preserve accuracy
2026-06-01 21:52:31 -04:00
Ed Hennis
261508a0ec
Merge remote-tracking branch 'XRPLF/develop' into ximinez/number-round-maxrep-down
...
* XRPLF/develop:
ci: Check binaries separately from building them (7355)
ci: [DEPENDABOT] bump eps1lon/actions-label-merge-conflict from 3.0.3 to 3.1.0 (7375)
refactor: Use `STLedgerEntry` type aliases instead of `std::shared_ptr` (7282)
fix: Adjust xrpld systemd service and update timer (7374)
release: Bump version to 3.2.0-rc3 (7371)
fix: Pin overpayment principal reduction to exact on-grid value (7360)
fix: Improve upward rounding edge cases for Number::operator/= (7328)
refactor: Revert "perf: Remove unnecessary caches (5439)" (7359)
fix: Add zero domainID check for permissionedDomain (7362)
2026-06-01 15:33:34 -04:00
Ayaz Salikhov
d4cb68d5a1
ci: Check binaries separately from building them ( #7355 )
...
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com >
2026-06-01 16:47:01 +00:00