Bug 1453877 - Remove unused RestyleHintData struct. r?xidorn
And fix a comment mentioning nsCSSSelectorList that I came across.
MozReview-Commit-ID: 1BOcDqV5dUr
--- a/dom/base/nsDocument.cpp
+++ b/dom/base/nsDocument.cpp
@@ -1312,19 +1312,19 @@ nsIDocument::SelectorCache::~SelectorCac
void nsIDocument::SelectorCache::NotifyExpired(SelectorCacheKey* aSelector)
{
MOZ_ASSERT(NS_IsMainThread());
MOZ_ASSERT(aSelector);
// There is no guarantee that this method won't be re-entered when selector
// matching is ongoing because "memory-pressure" could be notified immediately
// when OOM happens according to the design of nsExpirationTracker.
- // The perfect solution is to delete the |aSelector| and its nsCSSSelectorList
- // in mTable asynchronously.
- // We remove these objects synchronously for now because NotifiyExpired() will
+ // The perfect solution is to delete the |aSelector| and its
+ // RawServoSelectorList in mTable asynchronously.
+ // We remove these objects synchronously for now because NotifyExpired() will
// never be triggered by "memory-pressure" which is not implemented yet in
// the stage 2 of mozalloc_handle_oom().
// Once these objects are removed asynchronously, we should update the warning
// added in mozalloc_handle_oom() as well.
RemoveObject(aSelector);
mTable.Remove(aSelector->mKey);
delete aSelector;
}
--- a/layout/base/nsChangeHint.h
+++ b/layout/base/nsChangeHint.h
@@ -8,18 +8,16 @@
#ifndef nsChangeHint_h___
#define nsChangeHint_h___
#include "mozilla/Types.h"
#include "nsDebug.h"
#include "nsTArray.h"
-struct nsCSSSelector;
-
// Defines for various style related constants
enum nsChangeHint : uint32_t {
nsChangeHint_Empty = 0,
// change was visual only (e.g., COLOR=)
// Invalidates all descendant frames (including following
// placeholders to out-of-flow frames).
@@ -659,24 +657,9 @@ inline constexpr nsRestyleHint operator^
nsRestyleHint_size_t(aRight));
}
inline nsRestyleHint operator^=(nsRestyleHint& aLeft, nsRestyleHint aRight)
{
return aLeft = aLeft ^ aRight;
}
-namespace mozilla {
-
-/**
- * Additional data used in conjunction with an nsRestyleHint to control the
- * restyle process.
- */
-struct RestyleHintData
-{
- // When eRestyle_SomeDescendants is used, this array contains the selectors
- // that identify which descendants will be restyled.
- nsTArray<nsCSSSelector*> mSelectorsForDescendants;
-};
-
-} // namespace mozilla
-
#endif /* nsChangeHint_h___ */