[INFER] Maybe fix build breaks.
authorBrian Hackett <bhackett1024@gmail.com>
Sun, 03 Apr 2011 19:54:19 -0700
changeset 74900 a58525f1f4bea5e544972ae39e4ba2ce14d20304
parent 74899 23faefaeb4a81eb8f7f2065440747db2de1b98d9
child 74901 013df702176d09a6206b1db08a4ab893ffccc667
push id2
push userbsmedberg@mozilla.com
push dateFri, 19 Aug 2011 14:38:13 +0000
milestone2.2a1pre
[INFER] Maybe fix build breaks.
js/src/jsarray.h
js/src/jsobj.h
js/src/jsobjinlines.h
js/src/jsstrinlines.h
js/src/xpconnect/src/xpcjsruntime.cpp
--- a/js/src/jsarray.h
+++ b/js/src/jsarray.h
@@ -178,36 +178,16 @@ js_IdIsIndex(jsid id, jsuint *indexp)
     }
 
     if (JS_UNLIKELY(!JSID_IS_STRING(id)))
         return JS_FALSE;
 
     return js_StringIsIndex(JSID_TO_ATOM(id), indexp);
 }
 
-extern js::Class js_ArrayClass, js_SlowArrayClass;
-
-inline bool
-JSObject::isDenseArray() const
-{
-    return getClass() == &js_ArrayClass;
-}
-
-inline bool
-JSObject::isSlowArray() const
-{
-    return getClass() == &js_SlowArrayClass;
-}
-
-inline bool
-JSObject::isArray() const
-{
-    return isDenseArray() || isSlowArray();
-}
-
 /*
  * Dense arrays are not native -- aobj->isNative() for a dense array aobj
  * results in false, meaning aobj->map does not point to a js::Shape.
  *
  * But Array methods are called via aobj.sort(), e.g., and the interpreter and
  * the trace recorder must consult the property cache in order to perform well.
  * The cache works only for native objects.
  *
--- a/js/src/jsobj.h
+++ b/js/src/jsobj.h
@@ -1412,16 +1412,36 @@ class JSValueArray {
 class ValueArray {
   public:
     js::Value *array;
     size_t length;
 
     ValueArray(js::Value *v, size_t c) : array(v), length(c) {}
 };
 
+extern js::Class js_ArrayClass, js_SlowArrayClass;
+
+inline bool
+JSObject::isDenseArray() const
+{
+    return getClass() == &js_ArrayClass;
+}
+
+inline bool
+JSObject::isSlowArray() const
+{
+    return getClass() == &js_SlowArrayClass;
+}
+
+inline bool
+JSObject::isArray() const
+{
+    return isDenseArray() || isSlowArray();
+}
+
 extern js::Class js_ObjectClass;
 extern js::Class js_WithClass;
 extern js::Class js_BlockClass;
 
 inline bool JSObject::isObject() const { return getClass() == &js_ObjectClass; }
 inline bool JSObject::isWith() const   { return getClass() == &js_WithClass; }
 inline bool JSObject::isBlock() const  { return getClass() == &js_BlockClass; }
 
--- a/js/src/jsobjinlines.h
+++ b/js/src/jsobjinlines.h
@@ -48,17 +48,16 @@
 #include "jsiter.h"
 #include "jslock.h"
 #include "jsobj.h"
 #include "jsprobes.h"
 #include "jspropertytree.h"
 #include "jsproxy.h"
 #include "jsscope.h"
 #include "jsstaticcheck.h"
-#include "jsstdint.h"
 #include "jsxml.h"
 
 /* Headers included for inline implementations used by this header. */
 #include "jsbool.h"
 #include "jscntxt.h"
 #include "jsnum.h"
 #include "jsinferinlines.h"
 #include "jsscopeinlines.h"
--- a/js/src/jsstrinlines.h
+++ b/js/src/jsstrinlines.h
@@ -39,17 +39,17 @@
 
 #ifndef jsstrinlines_h___
 #define jsstrinlines_h___
 
 #include "jsatom.h"
 #include "jsstr.h"
 
 #include "jscntxtinlines.h"
-#include "jsobjinlines.h"
+#include "jsgcinlines.h"
 
 namespace js {
 
 static inline bool
 CheckStringLength(JSContext *cx, size_t length)
 {
     if (JS_UNLIKELY(length > JSString::MAX_LENGTH)) {
         if (JS_ON_TRACE(cx)) {
--- a/js/src/xpconnect/src/xpcjsruntime.cpp
+++ b/js/src/xpconnect/src/xpcjsruntime.cpp
@@ -625,26 +625,27 @@ DoDeferredRelease(nsTArray<T> &array)
 
 static JSDHashOperator
 SweepWaiverWrappers(JSDHashTable *table, JSDHashEntryHdr *hdr,
                     uint32 number, void *arg)
 {
     JSContext *cx = (JSContext *)arg;
     JSObject *key = ((JSObject2JSObjectMap::Entry *)hdr)->key;
     JSObject *value = ((JSObject2JSObjectMap::Entry *)hdr)->value;
-    if(IsAboutToBeFinalized(cx, key) || IsAboutToBeFinalized(cx, value))
+
+    if(JS_IsAboutToBeFinalized(cx, key) || JS_IsAboutToBeFinalized(cx, value))
         return JS_DHASH_REMOVE;
     return JS_DHASH_NEXT;
 }
 
 static PLDHashOperator
 SweepExpandos(XPCWrappedNative *wn, JSObject *&expando, void *arg)
 {
     JSContext *cx = (JSContext *)arg;
-    return IsAboutToBeFinalized(cx, wn->GetFlatJSObjectPreserveColor())
+    return JS_IsAboutToBeFinalized(cx, wn->GetFlatJSObjectPreserveColor())
            ? PL_DHASH_REMOVE
            : PL_DHASH_NEXT;
 }
 
 static PLDHashOperator
 SweepCompartment(nsCStringHashKey& aKey, JSCompartment *compartment, void *aClosure)
 {
     xpc::CompartmentPrivate *priv = (xpc::CompartmentPrivate *)