mirror of
https://github.com/XRPLF/rippled.git
synced 2025-11-26 05:55:51 +00:00
Modernize code:
* Clean STBase-derived class creation interfaces * Annotate overriden STBase virtual functions * Optimize path deserialization * Prefer range-based for * Prefer std::unique_ptr * Remove BOOST_FOREACH
This commit is contained in:
@@ -24,6 +24,7 @@
|
||||
#include <ripple/core/ConfigSections.h>
|
||||
#include <boost/format.hpp>
|
||||
#include <boost/tokenizer.hpp>
|
||||
#include <algorithm>
|
||||
|
||||
namespace ripple {
|
||||
/** Track the list of "amendments"
|
||||
@@ -498,16 +499,19 @@ void
|
||||
AmendmentTableImpl<AppApiFacade>::doValidation (Ledger::ref lastClosedLedger,
|
||||
STObject& baseValidation)
|
||||
{
|
||||
amendmentList_t lAmendments = getDesired();
|
||||
auto lAmendments = getDesired();
|
||||
|
||||
if (lAmendments.empty())
|
||||
return;
|
||||
|
||||
STVector256 vAmendments (sfAmendments);
|
||||
for (auto const& uAmendment : lAmendments)
|
||||
vAmendments.push_back (uAmendment);
|
||||
vAmendments.sort ();
|
||||
baseValidation.setFieldV256 (sfAmendments, vAmendments);
|
||||
STVector256 amendments (sfAmendments);
|
||||
|
||||
for (auto const& id : lAmendments)
|
||||
amendments.push_back (id);
|
||||
|
||||
std::sort (amendments.begin (), amendments.end ());
|
||||
|
||||
baseValidation.setFieldV256 (sfAmendments, amendments);
|
||||
}
|
||||
|
||||
template<class AppApiFacade>
|
||||
|
||||
Reference in New Issue
Block a user