Bug 1447442 - Part 3: Remove JSValueArray and ValueArray. r=jorendorff

--HG--
extra : rebase_source : c564d934f2e39d8282888e001fce4e8f0b83dba5
This commit is contained in:
André Bargull 2018-04-13 02:25:59 -07:00
parent b8ae21d64c
commit f2a242df05
3 changed files with 1 additions and 27 deletions

View File

@ -1329,7 +1329,7 @@ JS_PUBLIC_API(bool)
JS::detail::ComputeThis(JSContext* cx, Value* vp, MutableHandleObject thisObject)
{
AssertHeapIsIdle();
assertSameCompartment(cx, JSValueArray(vp, 2));
assertSameCompartment(cx, vp[0], vp[1]);
MutableHandleValue thisv = MutableHandleValue::fromMarkedLocation(&vp[1]);
if (!BoxNonStrictThis(cx, thisv, thisv))

View File

@ -139,16 +139,6 @@ class CompartmentChecker
check(i);
}
void check(const ValueArray& arr) {
for (size_t i = 0; i < arr.length; i++)
check(arr.array[i]);
}
void check(const JSValueArray& arr) {
for (size_t i = 0; i < arr.length; i++)
check(arr.array[i]);
}
void check(const JS::HandleValueArray& arr) {
for (size_t i = 0; i < arr.length(); i++)
check(arr[i]);

View File

@ -646,22 +646,6 @@ JSObject::writeBarrierPost(void* cellp, JSObject* prev, JSObject* next)
buffer->unputCell(static_cast<js::gc::Cell**>(cellp));
}
class JSValueArray {
public:
const js::Value* array;
size_t length;
JSValueArray(const js::Value* v, size_t c) : array(v), length(c) {}
};
class ValueArray {
public:
js::Value* array;
size_t length;
ValueArray(js::Value* v, size_t c) : array(v), length(c) {}
};
namespace js {
/*** Standard internal methods ********************************************************************