Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(919)

Unified Diff: src/objects.cc

Issue 820503005: Use SetOwnElement when creating splice records in array length setter (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | test/mjsunit/es7/regress/regress-443982.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects.cc
diff --git a/src/objects.cc b/src/objects.cc
index 9d17f1f8bd4e6f9275c00b106dee86174b2edae1..24fdf477a8e6683f49a58789bd1866895b25f146 100644
--- a/src/objects.cc
+++ b/src/objects.cc
@@ -11807,8 +11807,8 @@ MaybeHandle<Object> JSArray::SetElementsLength(
// Skip deletions where the property was an accessor, leaving holes
// in the array of old values.
if (old_values[i]->IsTheHole()) continue;
- JSObject::SetElement(
- deleted, indices[i] - index, old_values[i], NONE, SLOPPY).Assert();
+ JSObject::SetOwnElement(deleted, indices[i] - index, old_values[i],
+ SLOPPY).Assert();
}
SetProperty(deleted, isolate->factory()->length_string(),
« no previous file with comments | « no previous file | test/mjsunit/es7/regress/regress-443982.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698