Bug 1518812 - Redo the fix for bug 1516567 atop the moving of the relevant code to js/public/PropertySpec.h in bug 1517624. r=jandem
authorJeff Walden <jwalden@mit.edu>
Wed, 09 Jan 2019 08:45:05 -0800
changeset 510201 89ca00a3e30767aaf57562ac8c2e2b3994123de3
parent 510200 998ab57c13668895fc962260071b714cce36efdd
child 510202 8e746f670f430ceb0cb85fa8eebfe97cbe42ff01
child 510270 9429979e423ce7358a453d717175771aef609ee8
push id10547
push userffxbld-merge
push dateMon, 21 Jan 2019 13:03:58 +0000
treeherdermozilla-beta@24ec1916bffe [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjandem
bugs1518812, 1516567, 1517624
milestone66.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 1518812 - Redo the fix for bug 1516567 atop the moving of the relevant code to js/public/PropertySpec.h in bug 1517624. r=jandem
js/public/PropertySpec.h
--- a/js/public/PropertySpec.h
+++ b/js/public/PropertySpec.h
@@ -101,21 +101,19 @@ struct JSPropertySpec {
   static_assert(offsetof(SelfHostedWrapper, funname) ==
                     offsetof(JSNativeWrapper, info),
                 "JS_SELF_HOSTED* macros below require that "
                 "SelfHostedWrapper::funname overlay "
                 "JSNativeWrapper::info");
 
  private:
   void checkAccessorsAreNative() const {
-    MOZ_ASSERT(accessors.getter.native.op);
-    // We may not have a setter at all.  So all we can assert here, for the
-    // native case is that if we have a jitinfo for the setter then we have
-    // a setter op too.  This is good enough to make sure we don't have a
-    // SelfHostedWrapper for the setter.
+    // We may have a getter or a setter or both.  And whichever ones we have
+    // should not have a SelfHostedWrapper for the accessor.
+    MOZ_ASSERT_IF(accessors.getter.native.info, accessors.getter.native.op);
     MOZ_ASSERT_IF(accessors.setter.native.info, accessors.setter.native.op);
   }
 
   void checkAccessorsAreSelfHosted() const {
     MOZ_ASSERT(!accessors.getter.selfHosted.unused);
     MOZ_ASSERT(!accessors.setter.selfHosted.unused);
   }
 };