Bug 1457920: Remove FORWARD_INTERNAL. r=xidorn
authorEmilio Cobos Álvarez <emilio@crisal.io>
Mon, 30 Apr 2018 18:08:40 +0200
changeset 472610 eebbf9fbebc75dbe5f2d2a8aadc46950f86b7078
parent 472609 e7b20e0b67273e3dda4db315271530a3b043e2b2
child 472611 844f6c4c9356a951a972b1d3b6ef02af42289d4a
push id1728
push userjlund@mozilla.com
push dateMon, 18 Jun 2018 21:12:27 +0000
treeherdermozilla-release@c296fde26f5f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersxidorn
bugs1457920
milestone61.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1457920: Remove FORWARD_INTERNAL. r=xidorn MozReview-Commit-ID: EzWWdstzeev
layout/style/StyleSheet.cpp
--- a/layout/style/StyleSheet.cpp
+++ b/layout/style/StyleSheet.cpp
@@ -453,27 +453,24 @@ StyleSheet::AppendAllChildSheets(nsTArra
 {
   for (StyleSheet* child = GetFirstChild(); child; child = child->mNext) {
     aArray.AppendElement(child);
   }
 }
 
 // WebIDL CSSStyleSheet API
 
-#define FORWARD_INTERNAL(method_, args_) \
-  return AsServo()->method_ args_;
-
 dom::CSSRuleList*
 StyleSheet::GetCssRules(nsIPrincipal& aSubjectPrincipal,
                         ErrorResult& aRv)
 {
   if (!AreRulesAvailable(aSubjectPrincipal, aRv)) {
     return nullptr;
   }
-  FORWARD_INTERNAL(GetCssRulesInternal, ())
+  return GetCssRulesInternal();
 }
 
 void
 StyleSheet::GetSourceMapURL(nsAString& aSourceMapURL)
 {
   if (mInner->mSourceMapURL.IsEmpty()) {
     aSourceMapURL = mInner->mSourceMapURLFromComment;
   } else {
@@ -514,28 +511,28 @@ StyleSheet::GetDOMOwnerRule() const
 uint32_t
 StyleSheet::InsertRule(const nsAString& aRule, uint32_t aIndex,
                        nsIPrincipal& aSubjectPrincipal,
                        ErrorResult& aRv)
 {
   if (!AreRulesAvailable(aSubjectPrincipal, aRv)) {
     return 0;
   }
-  FORWARD_INTERNAL(InsertRuleInternal, (aRule, aIndex, aRv))
+  return InsertRuleInternal(aRule, aIndex, aRv);
 }
 
 void
 StyleSheet::DeleteRule(uint32_t aIndex,
                        nsIPrincipal& aSubjectPrincipal,
                        ErrorResult& aRv)
 {
   if (!AreRulesAvailable(aSubjectPrincipal, aRv)) {
     return;
   }
-  FORWARD_INTERNAL(DeleteRuleInternal, (aIndex, aRv))
+  return DeleteRuleInternal(aIndex, aRv);
 }
 
 nsresult
 StyleSheet::DeleteRuleFromGroup(css::GroupRule* aGroup, uint32_t aIndex)
 {
   NS_ENSURE_ARG_POINTER(aGroup);
   NS_ASSERTION(IsComplete(), "No deleting from an incomplete sheet!");
   RefPtr<css::Rule> rule = aGroup->GetStyleRuleAt(aIndex);
@@ -665,18 +662,16 @@ StyleSheet::FindOwningWindowInnerID() co
 
   if (windowID == 0 && mParent) {
     windowID = mParent->FindOwningWindowInnerID();
   }
 
   return windowID;
 }
 
-#undef FORWARD_INTERNAL
-
 void
 StyleSheet::UnparentChildren()
 {
   // XXXbz this is a little bogus; see the XXX comment where we
   // declare mFirstChild in StyleSheetInfo.
   for (StyleSheet* child = GetFirstChild();
        child;
        child = child->mNext) {