Backed out 5 changesets (bug 1305801) for ASan gtest bustage
Backed out changeset 0c95d5dec6d9 (bug 1305801) Backed out changeset bca0e706dbc5 (bug 1305801) Backed out changeset def8da367beb (bug 1305801) Backed out changeset 56ceae52d847 (bug 1305801) Backed out changeset 14457cc4c325 (bug 1305801)
This commit is contained in:
@@ -132,13 +132,13 @@ private:
|
||||
// for addition and indices to removal. See Bug 1283009.
|
||||
class TableUpdateV4 : public TableUpdate {
|
||||
public:
|
||||
struct PrefixStdString {
|
||||
struct PrefixString {
|
||||
private:
|
||||
std::string mStorage;
|
||||
nsDependentCSubstring mString;
|
||||
|
||||
public:
|
||||
explicit PrefixStdString(std::string& aString)
|
||||
explicit PrefixString(std::string& aString)
|
||||
{
|
||||
aString.swap(mStorage);
|
||||
mString.Rebind(mStorage.data(), mStorage.size());
|
||||
@@ -147,13 +147,12 @@ public:
|
||||
const nsACString& GetPrefixString() const { return mString; };
|
||||
};
|
||||
|
||||
typedef nsClassHashtable<nsUint32HashKey, PrefixStdString> PrefixStdStringMap;
|
||||
typedef nsClassHashtable<nsUint32HashKey, PrefixString> PrefixesStringMap;
|
||||
typedef nsTArray<int32_t> RemovalIndiceArray;
|
||||
|
||||
public:
|
||||
explicit TableUpdateV4(const nsACString& aTable)
|
||||
: TableUpdate(aTable)
|
||||
, mFullUpdate(false)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -162,22 +161,19 @@ public:
|
||||
return mPrefixesMap.IsEmpty() && mRemovalIndiceArray.IsEmpty();
|
||||
}
|
||||
|
||||
bool IsFullUpdate() const { return mFullUpdate; }
|
||||
PrefixStdStringMap& Prefixes() { return mPrefixesMap; }
|
||||
PrefixesStringMap& Prefixes() { return mPrefixesMap; }
|
||||
RemovalIndiceArray& RemovalIndices() { return mRemovalIndiceArray; }
|
||||
|
||||
// For downcasting.
|
||||
static const int TAG = 4;
|
||||
|
||||
void SetFullUpdate(bool aIsFullUpdate) { mFullUpdate = aIsFullUpdate; }
|
||||
void NewPrefixes(int32_t aSize, std::string& aPrefixes);
|
||||
void NewRemovalIndices(const uint32_t* aIndices, size_t aNumOfIndices);
|
||||
|
||||
private:
|
||||
virtual int Tag() const override { return TAG; }
|
||||
|
||||
bool mFullUpdate;
|
||||
PrefixStdStringMap mPrefixesMap;
|
||||
PrefixesStringMap mPrefixesMap;
|
||||
RemovalIndiceArray mRemovalIndiceArray;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user