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

Unified Diff: test/mjsunit/regress/regress-crbug-631917.js

Issue 2191663004: [fullcode][mips][mips64][ppc][s390] Avoid trashing of a home object when doing a count operation wi… (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 5 months 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
Index: test/mjsunit/regress/regress-crbug-631917.js
diff --git a/test/mjsunit/regress/regress-crbug-631917.js b/test/mjsunit/regress/regress-crbug-631917.js
new file mode 100644
index 0000000000000000000000000000000000000000..6e96239fed03ffeb79ba857167673e8c68de6985
--- /dev/null
+++ b/test/mjsunit/regress/regress-crbug-631917.js
@@ -0,0 +1,19 @@
+// Copyright 2016 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+var v = {};
+(function() {
+ var obj1 = { [v]: 42 };
+ var obj2 = {
+ testCounts() {
+ super[v]++;
+ return this[v];
+ }
+ }
+ Object.setPrototypeOf(obj2, obj1);
+ obj2.testCounts();
+
+ assertEquals(43, obj2.testCounts());
+ assertEquals(42, obj1[v]);
+}());
« src/full-codegen/mips/full-codegen-mips.cc ('K') | « src/full-codegen/s390/full-codegen-s390.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698