mirror of
https://github.com/XRPLF/rippled.git
synced 2025-12-06 17:27:55 +00:00
Use structured bindings in some places:
Most of the new uses either: * Replace some uses of `tie` * bind to pairs when iterating through maps
This commit is contained in:
@@ -1691,13 +1691,8 @@ ApplicationImp::getLastFullLedger()
|
||||
|
||||
try
|
||||
{
|
||||
std::shared_ptr<Ledger> ledger;
|
||||
std::uint32_t seq;
|
||||
uint256 hash;
|
||||
|
||||
std::tie (ledger, seq, hash) =
|
||||
loadLedgerHelper (
|
||||
"order by LedgerSeq desc limit 1", *this);
|
||||
auto const [ledger, seq, hash] =
|
||||
loadLedgerHelper("order by LedgerSeq desc limit 1", *this);
|
||||
|
||||
if (!ledger)
|
||||
return ledger;
|
||||
@@ -1998,9 +1993,9 @@ bool ApplicationImp::loadOldLedger (
|
||||
auto replayData =
|
||||
std::make_unique<LedgerReplay>(loadLedger, replayLedger);
|
||||
|
||||
for (auto const& it : replayData->orderedTxns())
|
||||
for (auto const& [_, tx] : replayData->orderedTxns())
|
||||
{
|
||||
std::shared_ptr<STTx const> const& tx = it.second;
|
||||
(void)_;
|
||||
auto txID = tx->getTransactionID();
|
||||
|
||||
auto s = std::make_shared <Serializer> ();
|
||||
|
||||
Reference in New Issue
Block a user