ARRAY_SIZE is not available on Linux-shared.
R=mstarzinger@chromium.org BUG= TEST= Review URL: https://chromiumcodereview.appspot.com/10718008 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@11950 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
parent
680797234c
commit
32e01d224d
@ -493,7 +493,7 @@ Handle<Value> Shell::CreateExternalArray(const Arguments& args,
|
|||||||
ASSERT(!try_catch.HasCaught() && array_buffer->IsFunction());
|
ASSERT(!try_catch.HasCaught() && array_buffer->IsFunction());
|
||||||
Handle<Value> buffer_args[] = { Uint32::New(byteLength) };
|
Handle<Value> buffer_args[] = { Uint32::New(byteLength) };
|
||||||
Handle<Value> result = Handle<Function>::Cast(array_buffer)->NewInstance(
|
Handle<Value> result = Handle<Function>::Cast(array_buffer)->NewInstance(
|
||||||
ARRAY_SIZE(buffer_args), buffer_args);
|
1, buffer_args);
|
||||||
if (try_catch.HasCaught()) return result;
|
if (try_catch.HasCaught()) return result;
|
||||||
buffer = result->ToObject();
|
buffer = result->ToObject();
|
||||||
}
|
}
|
||||||
@ -566,7 +566,7 @@ Handle<Value> Shell::SubArray(const Arguments& args) {
|
|||||||
Handle<Value> construct_args[] = {
|
Handle<Value> construct_args[] = {
|
||||||
buffer, Uint32::New(byteOffset), Uint32::New(length)
|
buffer, Uint32::New(byteOffset), Uint32::New(length)
|
||||||
};
|
};
|
||||||
return constructor->NewInstance(ARRAY_SIZE(construct_args), construct_args);
|
return constructor->NewInstance(3, construct_args);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user