Skip to content

style: Update clang-format to 21.1.8#6352

Merged
bthomee merged 3 commits intoXRPLF:developfrom
kuznetsss:Update_clang_format
Feb 16, 2026
Merged

style: Update clang-format to 21.1.8#6352
bthomee merged 3 commits intoXRPLF:developfrom
kuznetsss:Update_clang_format

Conversation

@kuznetsss
Copy link
Copy Markdown
Contributor

High Level Overview of Change

Updating clang-format to the latest version 21.1.8.

Context of Change

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Refactor (non-breaking change that only restructures code)
  • Performance (increase or change in throughput and/or latency)
  • Tests (you added tests for code that already exists, or your new feature included in this PR)
  • Documentation update
  • Chore (no impact to binary, e.g. .gitignore, formatting, dropping support for older tooling)
  • Release

API Impact

  • Public API: New feature (new methods and/or new fields)
  • Public API: Breaking change (in general, breaking changes should only impact the next api_version)
  • libxrpl change (any change that may affect libxrpl or dependents of libxrpl)
  • Peer protocol change (must be backward compatible or bump the peer protocol version)

Copilot AI review requested due to automatic review settings February 11, 2026 17:51
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates repository formatting tooling by bumping the clang-format pre-commit hook to v21.1.8 and reformatting affected C++ sources/tests to match the new formatter output.

Changes:

  • Bump pre-commit mirrors-clang-format hook revision to v21.1.8.
  • Apply clang-format-driven reflow/line-breaking updates across various C++ source and test files.
  • Ignore repository-root clangd cache directory (/.cache) in .gitignore.

Reviewed changes

Copilot reviewed 50 out of 57 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
src/xrpld/shamap/NodeFamily.cpp Formatting-only changes to constructor initializer layout.
src/xrpld/rpc/handlers/LedgerEntry.cpp Formatting-only changes to error-return wrapping/indentation.
src/xrpld/rpc/detail/RPCLedgerHelpers.cpp Formatting-only changes to wrapped error string formatting.
src/xrpld/overlay/detail/PeerImp.cpp Formatting-only change to post(...std::bind(...)) line wrapping.
src/xrpld/overlay/detail/OverlayImpl.h Formatting-only change to method declaration line breaks.
src/xrpld/overlay/detail/OverlayImpl.cpp Formatting-only change to async_wait call wrapping.
src/xrpld/overlay/detail/ConnectAttempt.cpp Formatting-only changes to timer async_wait wrapping.
src/xrpld/overlay/Slot.h Formatting-only changes to emplace/tuple construction wrapping.
src/xrpld/app/tx/detail/DepositPreauth.cpp Formatting-only change to exists(keylet::...) wrapping.
src/xrpld/app/tx/detail/ApplyContext.h Formatting-only change to visit signature wrapping.
src/xrpld/app/rdb/backend/detail/Node.cpp Formatting-only changes to SQL string building wrapping.
src/xrpld/app/misc/detail/ValidatorList.cpp Formatting-only change to for_each_available signature wrapping.
src/xrpld/app/misc/detail/Manifest.cpp Formatting-only change to reserve(std::accumulate(...)) wrapping.
src/xrpld/app/misc/detail/LendingHelpers.cpp Formatting-only changes to designated initializer formatting.
src/xrpld/app/misc/ValidatorList.h Formatting-only change to for_each_available signature wrapping.
src/xrpld/app/misc/CanonicalTXSet.cpp Formatting-only change to map_.insert(std::make_pair(...)) wrapping.
src/xrpld/app/main/GRPCServer.cpp Formatting-only change to addToRequests(std::make_shared<...>) wrapping.
src/xrpld/app/main/Application.cpp Formatting-only changes to member initialization wrapping.
src/xrpld/app/ledger/detail/LedgerReplayTask.cpp Formatting-only change to std::max(...) wrapping.
src/test/shamap/SHAMap_test.cpp Formatting-only changes to long uint256(...) literals wrapping.
src/test/rpc/LedgerEntry_test.cpp Formatting-only changes to long uint256::fromVoid(...) literals wrapping.
src/test/rpc/GRPCTestClientBase.h Formatting-only changes to stub/channel construction wrapping.
src/test/rpc/Feature_test.cpp Formatting-only changes to long string literal wrapping in expectations.
src/test/rpc/AccountObjects_test.cpp Formatting-only change to create_account_attestation(...) wrapping.
src/test/protocol/STParsedJSON_test.cpp Formatting-only changes to raw string literal construction wrapping.
src/test/overlay/compression_test.cpp Formatting-only changes to std::equal(...) call wrapping.
src/test/jtx/impl/mpt.cpp Formatting-only changes to conversion operator definition line breaks.
src/test/jtx/impl/amount.cpp Formatting-only changes to conversion operator definition line breaks.
src/test/core/Config_test.cpp Formatting-only changes to multi-part raw string concatenation wrapping.
src/test/beast/IPEndpoint_test.cpp Formatting-only changes to brace spacing in initializer lists (Windows-only section).
src/test/app/Vault_test.cpp Formatting-only changes to lambda parameter type wrapping/indentation.
src/test/app/Oracle_test.cpp Formatting-only changes to designated initializer wrapping/indentation.
src/test/app/Manifest_test.cpp Formatting-only changes to std::equal(...) call wrapping.
src/test/app/LedgerMaster_test.cpp Formatting-only changes to uint256(...) literal wrapping.
src/test/app/AMM_test.cpp Formatting-only changes to transaction argument wrapping/indentation.
src/libxrpl/shamap/SHAMapDelta.cpp Formatting-only changes to worker thread lambda wrapping/indentation.
src/libxrpl/server/Wallet.cpp Formatting-only changes to SQL string building wrapping.
src/libxrpl/server/JSONRPCUtil.cpp Formatting-only change to tm initialization ({} style).
src/libxrpl/protocol/digest.cpp Formatting-only changes to conversion operator definition line breaks.
src/libxrpl/protocol/Feature.cpp Formatting-only change to pointer-to-member template parameter spacing.
src/libxrpl/json/json_value.cpp Formatting-only changes to conversion operator definition line breaks.
src/libxrpl/basics/Number.cpp Formatting-only changes to conversion operator definition line breaks.
include/xrpl/server/detail/BaseWSPeer.h Formatting-only change to websocket decorator lambda wrapping.
include/xrpl/server/detail/BaseHTTPPeer.h Formatting-only change to post(...std::bind(...)) wrapping.
include/xrpl/protocol/TER.h Formatting-only changes to trailing return type formatting/wrapping.
include/xrpl/protocol/STVector256.h Formatting-only changes to conversion operator definition line breaks.
include/xrpl/protocol/STObject.h Formatting-only changes to method declarations and proxy conversion operators layout.
include/xrpl/protocol/STInteger.h Formatting-only changes to conversion operator definition line breaks.
include/xrpl/protocol/STBitString.h Formatting-only changes to conversion operator definition line breaks.
include/xrpl/protocol/STAmount.h Formatting-only changes to conversion operator definition line breaks.
include/xrpl/protocol/MultiApiJson.h Formatting-only indentation alignment in requires clauses.
include/xrpl/protocol/MPTAmount.h Formatting-only changes to conversion operator definition line breaks.
include/xrpl/protocol/IOUAmount.h Formatting-only changes to conversion operators definition line breaks.
include/xrpl/protocol/Feature.h Formatting-only brace spacing in FeatureBitset{rhs}.
include/xrpl/basics/SlabAllocator.h Formatting-only adjustment of clang-format on comment indentation.
.pre-commit-config.yaml Bumps clang-format hook pin to v21.1.8.
.gitignore Ignores repo-root /.cache directory (clangd cache).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread .pre-commit-config.yaml
Copilot AI review requested due to automatic review settings February 11, 2026 18:01
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 53 out of 60 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/xrpld/shamap/NodeFamily.cpp
Comment thread CONTRIBUTING.md
@codecov
Copy link
Copy Markdown

codecov Bot commented Feb 11, 2026

Codecov Report

❌ Patch coverage is 78.53107% with 38 lines in your changes missing coverage. Please review.
✅ Project coverage is 79.9%. Comparing base (ac0ad36) to head (5f588a5).
⚠️ Report is 1 commits behind head on develop.

Files with missing lines Patch % Lines
src/xrpld/app/main/GRPCServer.cpp 62.5% 12 Missing ⚠️
src/libxrpl/shamap/SHAMapDelta.cpp 68.2% 7 Missing ⚠️
src/xrpld/overlay/detail/ConnectAttempt.cpp 0.0% 6 Missing ⚠️
src/xrpld/app/main/Application.cpp 84.8% 5 Missing ⚠️
src/xrpld/app/rdb/backend/detail/Node.cpp 33.3% 4 Missing ⚠️
src/xrpld/overlay/Slot.h 81.8% 2 Missing ⚠️
src/xrpld/app/misc/detail/ValidatorList.cpp 0.0% 1 Missing ⚠️
src/xrpld/overlay/detail/PeerImp.cpp 0.0% 1 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##           develop   #6352   +/-   ##
=======================================
  Coverage     79.9%   79.9%           
=======================================
  Files          842     842           
  Lines        65538   65553   +15     
  Branches      7253    7245    -8     
=======================================
+ Hits         52380   52401   +21     
+ Misses       13158   13152    -6     
Files with missing lines Coverage Δ
include/xrpl/basics/IntrusivePointer.ipp 86.6% <100.0%> (ø)
include/xrpl/basics/SharedWeakCachePointer.ipp 75.5% <100.0%> (ø)
include/xrpl/basics/SlabAllocator.h 94.1% <ø> (ø)
include/xrpl/protocol/Feature.h 97.8% <ø> (ø)
include/xrpl/protocol/IOUAmount.h 100.0% <100.0%> (ø)
include/xrpl/protocol/MPTAmount.h 100.0% <ø> (ø)
include/xrpl/protocol/MultiApiJson.h 100.0% <ø> (ø)
include/xrpl/protocol/STAmount.h 95.6% <100.0%> (ø)
include/xrpl/protocol/STBitString.h 100.0% <ø> (ø)
include/xrpl/protocol/STInteger.h 100.0% <ø> (ø)
... and 31 more

... and 4 files with indirect coverage changes

Impacted file tree graph

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@kuznetsss kuznetsss added the Ready to merge *PR author* thinks it's ready to merge. Has passed code review. Perf sign-off may still be required. label Feb 16, 2026
@bthomee bthomee merged commit 958d8f3 into XRPLF:develop Feb 16, 2026
25 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Ready to merge *PR author* thinks it's ready to merge. Has passed code review. Perf sign-off may still be required.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants