Author: [EMAIL PROTECTED]
Date: Tue Sep 9 01:40:25 2008
New Revision: 230
Modified:
branches/bleeding_edge/src/array.js
branches/bleeding_edge/src/runtime.cc
Log:
Use RUNTIME_ASSERT instead of CHECK in runtime.cc.
Remove unused function from array.js.
Review URL: http://codereview.chromium.org/1659
Modified: branches/bleeding_edge/src/array.js
==============================================================================
--- branches/bleeding_edge/src/array.js (original)
+++ branches/bleeding_edge/src/array.js Tue Sep 9 01:40:25 2008
@@ -31,15 +31,6 @@
// -------------------------------------------------------------------
-// Determines if the array contains the element.
-function Contains(array, element) {
- var length = array.length;
- for (var i = 0; i < length; i++) {
- if (array[i] === element) return true;
- }
- return false;
-};
-
// Global list of arrays visited during toString, toLocaleString and
// join invocations.
Modified: branches/bleeding_edge/src/runtime.cc
==============================================================================
--- branches/bleeding_edge/src/runtime.cc (original)
+++ branches/bleeding_edge/src/runtime.cc Tue Sep 9 01:40:25 2008
@@ -3450,7 +3450,7 @@
ASSERT(args.length() == 2);
CONVERT_CHECKED(JSArray, array, args[0]);
CONVERT_CHECKED(JSArray, element, args[1]);
- CHECK(array->HasFastElements());
+ RUNTIME_ASSERT(array->HasFastElements());
int length = Smi::cast(array->length())->value();
FixedArray* elements = FixedArray::cast(array->elements());
for (int i = 0; i < length; i++) {
--~--~---------~--~----~------------~-------~--~----~
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
-~----------~----~----~----~------~----~------~--~---