mirror of
https://github.com/XRPLF/rippled.git
synced 2026-08-21 22:30:57 +00:00
fix: Silence -Wunused-variable on LoanPay asset asserts
Mark the raw pre-rounding projections `assetsAvailableAfterRaw` and `assetsTotalAfterRaw` in LoanPay::doApply as [[maybe_unused]]: they are only referenced from XRPL_ASSERT_PARTS, which is compiled out in Release (NDEBUG) builds, so clang's -Werror,-Wunused-variable was breaking the ubuntu-clang-release-amd64 and macos-arm64-release CI jobs. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -517,8 +517,9 @@ LoanPay::doApply()
|
||||
// check; the real post-rounding values are read back from the Vault SLE
|
||||
// further below, once addVaultAssets/associateAsset have actually
|
||||
// mutated and rounded it.
|
||||
Number const assetsAvailableAfterRaw = assetsAvailableBefore + totalPaidToVaultRounded;
|
||||
Number const assetsTotalAfterRaw = assetsTotalBefore + assetsTotalDelta;
|
||||
[[maybe_unused]] Number const assetsAvailableAfterRaw =
|
||||
assetsAvailableBefore + totalPaidToVaultRounded;
|
||||
[[maybe_unused]] Number const assetsTotalAfterRaw = assetsTotalBefore + assetsTotalDelta;
|
||||
|
||||
XRPL_ASSERT_PARTS(
|
||||
assetsAvailableAfterRaw <= assetsTotalAfterRaw,
|
||||
|
||||
Reference in New Issue
Block a user