Skip to content

Commit

Permalink
Let the compiler generate more comparison operators in WebCore
Browse files Browse the repository at this point in the history
https://bugs.webkit.org/show_bug.cgi?id=260943

Reviewed by Timothy Hatcher, Ryosuke Niwa and Darin Adler.

Let the compiler generate more comparison operators in WebCore now that we
support C++20.

* Source/WebCore/Modules/highlight/AppHighlightRangeData.h:
(WebCore::AppHighlightRangeData::NodePathComponent::operator== const): Deleted.
* Source/WebCore/Modules/indexeddb/IDBDatabaseIdentifier.h:
(WebCore::IDBDatabaseIdentifier::operator== const): Deleted.
* Source/WebCore/Modules/indexeddb/shared/IDBResourceIdentifier.h:
(WebCore::IDBResourceIdentifier::operator== const): Deleted.
* Source/WebCore/Modules/mediasession/MediaPositionState.h:
(WebCore::MediaPositionState::operator== const): Deleted.
* Source/WebCore/Modules/permissions/PermissionDescriptor.h:
(WebCore::PermissionDescriptor::operator== const): Deleted.
* Source/WebCore/Modules/webaudio/BaseAudioContext.h:
* Source/WebCore/PAL/pal/SessionID.h:
(PAL::SessionID::operator== const): Deleted.
* Source/WebCore/contentextensions/ContentExtensionActions.cpp:
(WebCore::ContentExtensions::ModifyHeadersAction::operator== const): Deleted.
(WebCore::ContentExtensions::ModifyHeadersAction::ModifyHeaderInfo::operator== const): Deleted.
(WebCore::ContentExtensions::RedirectAction::operator== const): Deleted.
(WebCore::ContentExtensions::RedirectAction::URLTransformAction::operator== const): Deleted.
(WebCore::ContentExtensions::RedirectAction::URLTransformAction::QueryTransform::operator== const): Deleted.
(WebCore::ContentExtensions::RedirectAction::URLTransformAction::QueryTransform::QueryKeyValue::operator== const): Deleted.
* Source/WebCore/contentextensions/ContentExtensionActions.h:
(WebCore::ContentExtensions::ActionWithoutMetadata::operator== const): Deleted.
(WebCore::ContentExtensions::ActionWithStringMetadata::operator== const): Deleted.
* Source/WebCore/contentextensions/ContentExtensionRule.h:
(WebCore::ContentExtensions::Trigger::operator== const): Deleted.
(WebCore::ContentExtensions::Action::operator== const): Deleted.
(WebCore::ContentExtensions::ContentExtensionRule::operator== const): Deleted.
* Source/WebCore/contentextensions/NFAToDFA.cpp:
* Source/WebCore/contentextensions/Term.h:
(WebCore::ContentExtensions::Term::CharacterSet::operator== const): Deleted.
(WebCore::ContentExtensions::Term::Group::operator== const): Deleted.
* Source/WebCore/css/CSSCounterStyleDescriptors.h:
(WebCore::CSSCounterStyleDescriptors::operator== const):
(WebCore::CSSCounterStyleDescriptors::Symbol::operator== const): Deleted.
(WebCore::CSSCounterStyleDescriptors::Pad::operator== const): Deleted.
(WebCore::CSSCounterStyleDescriptors::NegativeSymbols::operator== const): Deleted.
* Source/WebCore/css/CSSCounterStyleRegistry.cpp:
(WebCore::CSSCounterStyleRegistry::operator== const):
* Source/WebCore/css/CSSCustomPropertyValue.h:
* Source/WebCore/css/CSSFontFace.h:
* Source/WebCore/css/CSSGradientValue.cpp:
(WebCore::CSSLinearGradientValue::Angle::operator==):
(WebCore::CSSPrefixedLinearGradientValue::operator==):
(WebCore::CSSRadialGradientValue::operator==):
(WebCore::CSSPrefixedRadialGradientValue::operator==):
(WebCore::CSSConicGradientValue::operator==):
* Source/WebCore/css/CSSGradientValue.h:
(WebCore::CSSGradientColorInterpolationMethod::legacyMethod):
(WebCore::operator==):

Canonical link: https://commits.webkit.org/267512@main
  • Loading branch information
cdumez committed Aug 31, 2023
1 parent 7a9106c commit 32a30df
Show file tree
Hide file tree
Showing 18 changed files with 80 additions and 197 deletions.
5 changes: 1 addition & 4 deletions Source/WebCore/Modules/highlight/AppHighlightRangeData.h
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,7 @@ WTF_MAKE_FAST_ALLOCATED;
{
}

bool operator==(const NodePathComponent& other) const
{
return identifier == other.identifier && nodeName == other.nodeName && textData == other.textData && pathIndex == other.pathIndex;
}
friend bool operator==(const NodePathComponent&, const NodePathComponent&) = default;
};

using NodePath = Vector<NodePathComponent>;
Expand Down
5 changes: 1 addition & 4 deletions Source/WebCore/Modules/indexeddb/IDBDatabaseIdentifier.h
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,7 @@ class IDBDatabaseIdentifier {
return m_databaseName.isNull();
}

bool operator==(const IDBDatabaseIdentifier& other) const
{
return other.m_databaseName == m_databaseName && other.m_origin == m_origin && other.m_isTransient == m_isTransient;
}
friend bool operator==(const IDBDatabaseIdentifier&, const IDBDatabaseIdentifier&) = default;

const String& databaseName() const { return m_databaseName; }
const ClientOrigin& origin() const { return m_origin; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,11 +55,7 @@ class IDBResourceIdentifier {
return !m_resourceNumber && !m_idbConnectionIdentifier;
}

bool operator==(const IDBResourceIdentifier& other) const
{
return m_idbConnectionIdentifier == other.m_idbConnectionIdentifier
&& m_resourceNumber == other.m_resourceNumber;
}
friend bool operator==(const IDBResourceIdentifier&, const IDBResourceIdentifier&) = default;

IDBConnectionIdentifier connectionIdentifier() const { return m_idbConnectionIdentifier; }

Expand Down
2 changes: 1 addition & 1 deletion Source/WebCore/Modules/mediasession/MediaPositionState.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ struct MediaPositionState {

String toJSONString() const;

bool operator==(const MediaPositionState& other) const { return duration == other.duration && playbackRate == other.playbackRate && position == other.position; }
friend bool operator==(const MediaPositionState&, const MediaPositionState&) = default;
};

}
Expand Down
2 changes: 1 addition & 1 deletion Source/WebCore/Modules/permissions/PermissionDescriptor.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ namespace WebCore {
struct PermissionDescriptor {
PermissionName name;

bool operator==(const PermissionDescriptor& descriptor) const { return name == descriptor.name; }
friend bool operator==(PermissionDescriptor, PermissionDescriptor) = default;
};

} // namespace WebCore
2 changes: 1 addition & 1 deletion Source/WebCore/Modules/webaudio/BaseAudioContext.h
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,7 @@ class BaseAudioContext
TailProcessingNode& operator=(const TailProcessingNode&) = delete;
TailProcessingNode& operator=(TailProcessingNode&&) = delete;
AudioNode* operator->() const { return m_node.get(); }
bool operator==(const TailProcessingNode& other) const { return m_node == other.m_node; }
friend bool operator==(const TailProcessingNode&, const TailProcessingNode&) = default;
bool operator==(const AudioNode& node) const { return m_node == &node; }
private:
RefPtr<AudioNode> m_node;
Expand Down
2 changes: 1 addition & 1 deletion Source/WebCore/PAL/pal/SessionID.h
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ class SessionID {
bool isHashTableDeletedValue() const { return m_identifier == HashTableDeletedValueID; }

uint64_t toUInt64() const { return m_identifier; }
bool operator==(SessionID sessionID) const { return m_identifier == sessionID.m_identifier; }
friend bool operator==(SessionID, SessionID) = default;
bool isAlwaysOnLoggingAllowed() const { return !isEphemeral(); }

template<class Encoder> void encode(Encoder&) const;
Expand Down
44 changes: 0 additions & 44 deletions Source/WebCore/contentextensions/ContentExtensionActions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -130,14 +130,6 @@ ModifyHeadersAction ModifyHeadersAction::isolatedCopy() &&
return { crossThreadCopy(WTFMove(requestHeaders)), crossThreadCopy(WTFMove(responseHeaders)), crossThreadCopy(priority) };
}

bool ModifyHeadersAction::operator==(const ModifyHeadersAction& other) const
{
return other.hashTableType == this->hashTableType
&& other.requestHeaders == this->requestHeaders
&& other.responseHeaders == this->responseHeaders
&& other.priority == this->priority;
}

void ModifyHeadersAction::serialize(Vector<uint8_t>& vector) const
{
auto beginIndex = vector.size();
Expand Down Expand Up @@ -257,11 +249,6 @@ auto ModifyHeadersAction::ModifyHeaderInfo::isolatedCopy() && -> ModifyHeaderInf
return { crossThreadCopy(WTFMove(operation)) };
}

bool ModifyHeadersAction::ModifyHeaderInfo::operator==(const ModifyHeaderInfo& other) const
{
return other.operation == this->operation;
}

void ModifyHeadersAction::ModifyHeaderInfo::serialize(Vector<uint8_t>& vector) const
{
auto beginIndex = vector.size();
Expand Down Expand Up @@ -352,12 +339,6 @@ RedirectAction RedirectAction::isolatedCopy() &&
return { crossThreadCopy(WTFMove(action)) };
}

bool RedirectAction::operator==(const RedirectAction& other) const
{
return other.hashTableType == this->hashTableType
&& other.action == this->action;
}

void RedirectAction::serialize(Vector<uint8_t>& vector) const
{
auto beginIndex = vector.size();
Expand Down Expand Up @@ -559,18 +540,6 @@ auto RedirectAction::URLTransformAction::isolatedCopy() && -> URLTransformAction
crossThreadCopy(WTFMove(queryTransform)), crossThreadCopy(WTFMove(scheme)), crossThreadCopy(WTFMove(username)) };
}

bool RedirectAction::URLTransformAction::operator==(const URLTransformAction& other) const
{
return other.fragment == this->fragment
&& other.host == this->host
&& other.password == this->password
&& other.path == this->path
&& other.port == this->port
&& other.queryTransform == this->queryTransform
&& other.scheme == this->scheme
&& other.username == this->username;
}

void RedirectAction::URLTransformAction::serialize(Vector<uint8_t>& vector) const
{
uint8_t hasFragment = !!fragment;
Expand Down Expand Up @@ -853,12 +822,6 @@ auto RedirectAction::URLTransformAction::QueryTransform::isolatedCopy() && -> Qu
return { crossThreadCopy(WTFMove(addOrReplaceParams)), crossThreadCopy(WTFMove(removeParams)) };
}

bool RedirectAction::URLTransformAction::QueryTransform::operator==(const QueryTransform& other) const
{
return other.addOrReplaceParams == this->addOrReplaceParams
&& other.removeParams == this->removeParams;
}

void RedirectAction::URLTransformAction::QueryTransform::serialize(Vector<uint8_t>& vector) const
{
auto beginIndex = vector.size();
Expand Down Expand Up @@ -925,13 +888,6 @@ auto RedirectAction::URLTransformAction::QueryTransform::QueryKeyValue::parse(co
return { { WTFMove(key), replaceOnly, WTFMove(value) } };
}

bool RedirectAction::URLTransformAction::QueryTransform::QueryKeyValue::operator==(const QueryKeyValue& other) const
{
return other.key == this->key
&& other.replaceOnly == this->replaceOnly
&& other.value == this->value;
}

void RedirectAction::URLTransformAction::QueryTransform::QueryKeyValue::serialize(Vector<uint8_t>& vector) const
{
constexpr auto headerLength = sizeof(uint32_t) + sizeof(uint32_t) + sizeof(bool);
Expand Down
28 changes: 14 additions & 14 deletions Source/WebCore/contentextensions/ContentExtensionActions.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ using SerializedActionByte = uint8_t;

template<typename T> struct ActionWithoutMetadata {
T isolatedCopy() const { return { }; }
bool operator==(const ActionWithoutMetadata&) const { return true; }
friend bool operator==(const ActionWithoutMetadata&, const ActionWithoutMetadata&) = default;
void serialize(Vector<uint8_t>&) const { }
static T deserialize(std::span<const uint8_t>) { return { }; }
static size_t serializedLength(std::span<const uint8_t>) { return 0; }
Expand All @@ -53,7 +53,7 @@ template<typename T> struct ActionWithStringMetadata {
String string;
T isolatedCopy() const & { return { { string.isolatedCopy() } }; }
T isolatedCopy() && { return { { WTFMove(string).isolatedCopy() } }; }
bool operator==(const ActionWithStringMetadata& other) const { return other.string == this->string; }
friend bool operator==(const ActionWithStringMetadata&, const ActionWithStringMetadata&) = default;
void serialize(Vector<uint8_t>& vector) const { serializeString(vector, string); }
static T deserialize(std::span<const uint8_t> span) { return { { deserializeString(span) } }; }
static size_t serializedLength(std::span<const uint8_t> span) { return stringSerializedLength(span); }
Expand All @@ -76,30 +76,30 @@ struct WEBCORE_EXPORT ModifyHeadersAction {

AppendOperation isolatedCopy() const & { return { header.isolatedCopy(), value.isolatedCopy() }; }
AppendOperation isolatedCopy() && { return { WTFMove(header).isolatedCopy(), WTFMove(value).isolatedCopy() }; }
bool operator==(const AppendOperation& other) const { return other.header == this->header && other.value == this->value; }
friend bool operator==(const AppendOperation&, const AppendOperation&) = default;
};
struct SetOperation {
String header;
String value;

SetOperation isolatedCopy() const & { return { header.isolatedCopy(), value.isolatedCopy() }; }
SetOperation isolatedCopy() && { return { WTFMove(header).isolatedCopy(), WTFMove(value).isolatedCopy() }; }
bool operator==(const SetOperation& other) const { return other.header == this->header && other.value == this->value; }
friend bool operator==(const SetOperation&, const SetOperation&) = default;
};
struct RemoveOperation {
String header;

RemoveOperation isolatedCopy() const & { return { header.isolatedCopy() }; }
RemoveOperation isolatedCopy() && { return { WTFMove(header).isolatedCopy() }; }
bool operator==(const RemoveOperation& other) const { return other.header == this->header; }
friend bool operator==(const RemoveOperation&, const RemoveOperation&) = default;
};
using OperationVariant = std::variant<AppendOperation, SetOperation, RemoveOperation>;
OperationVariant operation;

static Expected<ModifyHeaderInfo, std::error_code> parse(const JSON::Value&);
ModifyHeaderInfo isolatedCopy() const &;
ModifyHeaderInfo isolatedCopy() &&;
bool operator==(const ModifyHeaderInfo&) const;
friend bool operator==(const ModifyHeaderInfo&, const ModifyHeaderInfo&) = default;
void serialize(Vector<uint8_t>&) const;
static ModifyHeaderInfo deserialize(std::span<const uint8_t>);
static size_t serializedLength(std::span<const uint8_t>);
Expand All @@ -126,7 +126,7 @@ struct WEBCORE_EXPORT ModifyHeadersAction {
static Expected<ModifyHeadersAction, std::error_code> parse(const JSON::Object&);
ModifyHeadersAction isolatedCopy() const &;
ModifyHeadersAction isolatedCopy() &&;
bool operator==(const ModifyHeadersAction&) const;
friend bool operator==(const ModifyHeadersAction&, const ModifyHeadersAction&) = default;
void serialize(Vector<uint8_t>&) const;
static ModifyHeadersAction deserialize(std::span<const uint8_t>);
static size_t serializedLength(std::span<const uint8_t>);
Expand All @@ -139,7 +139,7 @@ struct WEBCORE_EXPORT RedirectAction {

ExtensionPathAction isolatedCopy() const & { return { extensionPath.isolatedCopy() }; }
ExtensionPathAction isolatedCopy() && { return { WTFMove(extensionPath).isolatedCopy() }; }
bool operator==(const ExtensionPathAction& other) const { return other.extensionPath == this->extensionPath; }
friend bool operator==(const ExtensionPathAction&, const ExtensionPathAction&) = default;
};
struct RegexSubstitutionAction {
String regexSubstitution;
Expand All @@ -149,7 +149,7 @@ struct WEBCORE_EXPORT RedirectAction {
RegexSubstitutionAction isolatedCopy() && { return { WTFMove(regexSubstitution).isolatedCopy(), WTFMove(regexFilter).isolatedCopy() }; }
void serialize(Vector<uint8_t>&) const;
static RegexSubstitutionAction deserialize(std::span<const uint8_t>);
bool operator==(const RegexSubstitutionAction& other) const { return other.regexSubstitution == this->regexSubstitution && other.regexFilter == this->regexFilter; }
friend bool operator==(const RegexSubstitutionAction&, const RegexSubstitutionAction&) = default;
WEBCORE_EXPORT void applyToURL(URL&) const;
};
struct URLTransformAction {
Expand All @@ -162,7 +162,7 @@ struct WEBCORE_EXPORT RedirectAction {
static Expected<QueryKeyValue, std::error_code> parse(const JSON::Value&);
QueryKeyValue isolatedCopy() const & { return { key.isolatedCopy(), replaceOnly, value.isolatedCopy() }; }
QueryKeyValue isolatedCopy() && { return { WTFMove(key).isolatedCopy(), replaceOnly, WTFMove(value).isolatedCopy() }; }
bool operator==(const QueryKeyValue&) const;
friend bool operator==(const QueryKeyValue&, const QueryKeyValue&) = default;
void serialize(Vector<uint8_t>&) const;
static QueryKeyValue deserialize(std::span<const uint8_t>);
static size_t serializedLength(std::span<const uint8_t>);
Expand All @@ -174,7 +174,7 @@ struct WEBCORE_EXPORT RedirectAction {
static Expected<QueryTransform, std::error_code> parse(const JSON::Object&);
QueryTransform isolatedCopy() const &;
QueryTransform isolatedCopy() &&;
bool operator==(const QueryTransform&) const;
friend bool operator==(const QueryTransform&, const QueryTransform&) = default;
void serialize(Vector<uint8_t>&) const;
static QueryTransform deserialize(std::span<const uint8_t>);
static size_t serializedLength(std::span<const uint8_t>);
Expand All @@ -194,7 +194,7 @@ struct WEBCORE_EXPORT RedirectAction {
static Expected<URLTransformAction, std::error_code> parse(const JSON::Object&);
URLTransformAction isolatedCopy() const &;
URLTransformAction isolatedCopy() &&;
bool operator==(const URLTransformAction&) const;
friend bool operator==(const URLTransformAction&, const URLTransformAction&) = default;
void serialize(Vector<uint8_t>&) const;
static URLTransformAction deserialize(std::span<const uint8_t>);
static size_t serializedLength(std::span<const uint8_t>);
Expand All @@ -205,7 +205,7 @@ struct WEBCORE_EXPORT RedirectAction {

URLAction isolatedCopy() const & { return { url.isolatedCopy() }; }
URLAction isolatedCopy() && { return { WTFMove(url).isolatedCopy() }; }
bool operator==(const URLAction& other) const { return other.url == this->url; }
friend bool operator==(const URLAction&, const URLAction&) = default;
};

enum class HashTableType : uint8_t { Empty, Deleted, Full } hashTableType;
Expand All @@ -225,7 +225,7 @@ struct WEBCORE_EXPORT RedirectAction {
static Expected<RedirectAction, std::error_code> parse(const JSON::Object&, const String& urlFilter);
RedirectAction isolatedCopy() const &;
RedirectAction isolatedCopy() &&;
bool operator==(const RedirectAction&) const;
friend bool operator==(const RedirectAction&, const RedirectAction&) = default;
void serialize(Vector<uint8_t>&) const;
static RedirectAction deserialize(std::span<const uint8_t>);
static size_t serializedLength(std::span<const uint8_t>);
Expand Down
17 changes: 3 additions & 14 deletions Source/WebCore/contentextensions/ContentExtensionRule.h
Original file line number Diff line number Diff line change
Expand Up @@ -70,15 +70,7 @@ struct Trigger {
&& conditions.isEmpty();
}

bool operator==(const Trigger& other) const
{
return urlFilter == other.urlFilter
&& urlFilterIsCaseSensitive == other.urlFilterIsCaseSensitive
&& topURLFilterIsCaseSensitive == other.topURLFilterIsCaseSensitive
&& frameURLFilterIsCaseSensitive == other.frameURLFilterIsCaseSensitive
&& flags == other.flags
&& conditions == other.conditions;
}
friend bool operator==(const Trigger&, const Trigger&) = default;
};

inline void add(Hasher& hasher, const Trigger& trigger)
Expand Down Expand Up @@ -127,7 +119,7 @@ struct Action {
Action(ActionData&& data)
: m_data(WTFMove(data)) { }

bool operator==(const Action& other) const { return m_data == other.m_data; }
friend bool operator==(const Action&, const Action&) = default;

const ActionData& data() const { return m_data; }

Expand Down Expand Up @@ -161,10 +153,7 @@ class ContentExtensionRule {

ContentExtensionRule isolatedCopy() const & { return { m_trigger.isolatedCopy(), m_action.isolatedCopy() }; }
ContentExtensionRule isolatedCopy() && { return { WTFMove(m_trigger).isolatedCopy(), WTFMove(m_action).isolatedCopy() }; }
bool operator==(const ContentExtensionRule& other) const
{
return m_trigger == other.m_trigger && m_action == other.m_action;
}
friend bool operator==(const ContentExtensionRule&, const ContentExtensionRule&) = default;

private:
Trigger m_trigger;
Expand Down
5 changes: 1 addition & 4 deletions Source/WebCore/contentextensions/NFAToDFA.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -162,10 +162,7 @@ class UniqueNodeIdSet {
fastFree(m_uniqueNodeIdSetBuffer);
}

bool operator==(const UniqueNodeIdSet& other) const
{
return m_uniqueNodeIdSetBuffer == other.m_uniqueNodeIdSetBuffer;
}
friend bool operator==(const UniqueNodeIdSet&, const UniqueNodeIdSet&) = default;

bool operator==(const NodeIdSet& other) const
{
Expand Down
12 changes: 2 additions & 10 deletions Source/WebCore/contentextensions/Term.h
Original file line number Diff line number Diff line change
Expand Up @@ -158,12 +158,7 @@ class Term {
return WTF::bitCount(m_characters[0]) + WTF::bitCount(m_characters[1]);
}

bool operator==(const CharacterSet& other) const
{
return other.m_inverted == m_inverted
&& other.m_characters[0] == m_characters[0]
&& other.m_characters[1] == m_characters[1];
}
friend bool operator==(const CharacterSet&, const CharacterSet&) = default;

private:
friend void add(Hasher&, const CharacterSet&);
Expand All @@ -176,10 +171,7 @@ class Term {
struct Group {
Vector<Term> terms;

bool operator==(const Group& other) const
{
return other.terms == terms;
}
friend bool operator==(const Group&, const Group&) = default;
};
friend void add(Hasher&, const Term::Group&);

Expand Down
7 changes: 4 additions & 3 deletions Source/WebCore/css/CSSCounterStyleDescriptors.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ struct CSSCounterStyleDescriptors {
struct Symbol {
bool isCustomIdent { false };
String text;
bool operator==(const Symbol& other) const { return isCustomIdent == other.isCustomIdent && text == other.text; }
friend bool operator==(const Symbol&, const Symbol&) = default;
String cssText() const;
};
using AdditiveSymbols = Vector<std::pair<Symbol, unsigned>>;
Expand Down Expand Up @@ -72,13 +72,13 @@ struct CSSCounterStyleDescriptors {
struct Pad {
unsigned m_padMinimumLength = 0;
Symbol m_padSymbol;
bool operator==(const Pad& other) const { return m_padMinimumLength == other.m_padMinimumLength && m_padSymbol == other.m_padSymbol; }
friend bool operator==(const Pad&, const Pad&) = default;
String cssText() const;
};
struct NegativeSymbols {
Symbol m_prefix = { false, "-"_s };
Symbol m_suffix;
bool operator==(const NegativeSymbols& other) const { return m_prefix == other.m_prefix && m_suffix == other.m_suffix; }
friend bool operator==(const NegativeSymbols&, const NegativeSymbols&) = default;
};
enum class ExplicitlySetDescriptors: uint16_t {
System = 1 << 0,
Expand All @@ -97,6 +97,7 @@ struct CSSCounterStyleDescriptors {
static CSSCounterStyleDescriptors create(AtomString name, const StyleProperties&);
bool operator==(const CSSCounterStyleDescriptors& other) const
{
// Intentionally doesn't check m_isExtendedResolved.
return m_name == other.m_name
&& m_system == other.m_system
&& m_negativeSymbols == other.m_negativeSymbols
Expand Down
Loading

0 comments on commit 32a30df

Please sign in to comment.