mirror of
https://github.com/XRPLF/rippled.git
synced 2025-11-27 14:35:52 +00:00
Cleanup and log, no semantic changes. SerializedType::operator=(const SerializedType &)
This commit is contained in:
@@ -19,6 +19,15 @@ DECLARE_INSTANCE(SerializedValue);
|
||||
STAmount saZero(CURRENCY_ONE, ACCOUNT_ONE, 0);
|
||||
STAmount saOne(CURRENCY_ONE, ACCOUNT_ONE, 1);
|
||||
|
||||
SerializedType& SerializedType::operator=(const SerializedType& t)
|
||||
{
|
||||
if ((t.fName != fName) && fName->isUseful() && t.fName->isUseful())
|
||||
Log(lsWARNING) << "Caution: " << t.fName->getName() << " not replacing " << fName->getName();
|
||||
if (!fName->isUseful()) fName = t.fName;
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
||||
void STPathSet::printDebug() {
|
||||
for (int i = 0; i < value.size(); i++) {
|
||||
std::cout << i << ": ";
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
#include "Serializer.h"
|
||||
#include "FieldNames.h"
|
||||
#include "InstanceCounter.h"
|
||||
#include "Log.h"
|
||||
|
||||
enum PathFlags
|
||||
{
|
||||
@@ -68,8 +69,8 @@ public:
|
||||
|
||||
void addFieldID(Serializer& s) const { s.addFieldID(fName->fieldType, fName->fieldValue); }
|
||||
|
||||
SerializedType& operator=(const SerializedType& t)
|
||||
{ if (!fName->fieldCode) fName = t.fName; return *this; }
|
||||
SerializedType& operator=(const SerializedType& t);
|
||||
|
||||
bool operator==(const SerializedType& t) const
|
||||
{ return (getSType() == t.getSType()) && isEquivalent(t); }
|
||||
bool operator!=(const SerializedType& t) const
|
||||
|
||||
Reference in New Issue
Block a user