mirror of
https://github.com/XRPLF/rippled.git
synced 2026-07-30 18:40:28 +00:00
refactor: Add simple clang-tidy readability checks (#6556)
This change enables the following clang-tidy checks: - readability-avoid-nested-conditional-operator, - readability-avoid-return-with-void-value, - readability-braces-around-statements, - readability-const-return-type, - readability-container-contains, - readability-container-size-empty, - readability-else-after-return, - readability-make-member-function-const, - readability-redundant-casting, - readability-redundant-inline-specifier, - readability-redundant-member-init, - readability-redundant-string-init, - readability-reference-to-constructed-temporary, - readability-static-definition
This commit is contained in:
@@ -33,8 +33,10 @@ public:
|
||||
if (id == 0)
|
||||
{
|
||||
for (auto const link : net.links(this))
|
||||
{
|
||||
net.send(
|
||||
this, link.target, [&, to = link.target] { to->receive(net, this, 1); });
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -51,9 +53,11 @@ public:
|
||||
if (m < 5)
|
||||
{
|
||||
for (auto const link : net.links(this))
|
||||
{
|
||||
net.send(this, link.target, [&, mm = m, to = link.target] {
|
||||
to->receive(net, this, mm);
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user