chore: Enable clang-tidy misc checks (#6655)

This commit is contained in:
Alex Kremer
2026-03-31 18:29:45 +01:00
committed by GitHub
parent c3fae847f3
commit 2502befb42
469 changed files with 3915 additions and 3965 deletions

View File

@@ -163,7 +163,7 @@ public:
buildTransaction(Logs& logs)
{
Env env(*this, envconfig());
int fund = 10000;
int const fund = 10000;
auto const alice = Account("alice");
auto const bob = Account("bob");
env.fund(XRP(fund), "alice", "bob");
@@ -205,7 +205,7 @@ public:
uint256 const hash(xrpl::sha512Half(123456789));
getLedger->set_ledgerhash(hash.begin(), hash.size());
getLedger->set_ledgerseq(123456789);
xrpl::SHAMapNodeID sha(64, hash);
xrpl::SHAMapNodeID const sha(64, hash);
getLedger->add_nodeids(sha.getRawString());
getLedger->set_requestcookie(123456789);
getLedger->set_querytype(protocol::qtINDIRECT);
@@ -268,7 +268,7 @@ public:
uint256 hash(xrpl::sha512Half(i));
auto object = getObject->add_objects();
object->set_hash(hash.data(), hash.size());
xrpl::SHAMapNodeID sha(64, hash);
xrpl::SHAMapNodeID const sha(64, hash);
object->set_nodeid(sha.getRawString());
object->set_index("");
object->set_data("");
@@ -295,7 +295,7 @@ public:
st.add(s);
list->set_manifest(s.data(), s.size());
list->set_version(3);
STObject signature(sfSignature);
STObject const signature(sfSignature);
xrpl::sign(st, HashPrefix::manifest, KeyType::ed25519, std::get<1>(signing));
Serializer s1;
st.add(s1);
@@ -322,7 +322,7 @@ public:
st.add(s);
list->set_manifest(s.data(), s.size());
list->set_version(4);
STObject signature(sfSignature);
STObject const signature(sfSignature);
xrpl::sign(st, HashPrefix::manifest, KeyType::ed25519, std::get<1>(signing));
Serializer s1;
st.add(s1);
@@ -338,14 +338,14 @@ public:
auto thresh = beast::severities::Severity::kInfo;
auto logs = std::make_unique<Logs>(thresh);
protocol::TMManifests manifests;
protocol::TMEndpoints endpoints;
protocol::TMTransaction transaction;
protocol::TMGetLedger get_ledger;
protocol::TMLedgerData ledger_data;
protocol::TMGetObjectByHash get_object;
protocol::TMValidatorList validator_list;
protocol::TMValidatorListCollection validator_list_collection;
protocol::TMManifests const manifests;
protocol::TMEndpoints const endpoints;
protocol::TMTransaction const transaction;
protocol::TMGetLedger const get_ledger;
protocol::TMLedgerData const ledger_data;
protocol::TMGetObjectByHash const get_object;
protocol::TMValidatorList const validator_list;
protocol::TMValidatorListCollection const validator_list_collection;
// 4.5KB
doTest(buildManifests(20), protocol::mtMANIFESTS, 4, "TMManifests20");
@@ -399,7 +399,7 @@ public:
return env;
};
auto handshake = [&](int outboundEnable, int inboundEnable) {
beast::IP::Address addr = boost::asio::ip::make_address("172.1.1.100");
beast::IP::Address const addr = boost::asio::ip::make_address("172.1.1.100");
auto env = getEnv(outboundEnable);
auto request = xrpl::makeRequest(