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

Unified Diff: test/mjsunit/object-create.js

Issue 2385423005: [stubs] Implement fast TF Builtin for Object.create (Closed)
Patch Set: removing unused symbol Created 4 years, 2 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
« no previous file with comments | « test/cctest/test-code-stub-assembler.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/object-create.js
diff --git a/test/mjsunit/object-create.js b/test/mjsunit/object-create.js
index d8385842a384fd614f374638c290fdbe59a1d3d4..d4f9e03c800d01403590244be6111f3ef601524d 100644
--- a/test/mjsunit/object-create.js
+++ b/test/mjsunit/object-create.js
@@ -248,3 +248,14 @@ for (x in sonOfTricky) {
sum += sonOfTricky[x];
}
assertEquals(16, sum);
+
+
+(function createWithEmptyProtoInfoCreateMap() {
+ var proto = {a:1};
+ var instance = {__proto__: proto };
+ // Try force creation of prototype info on proto by loading a proto property.
+ assertEquals(instance.a, 1);
+ var result = Object.create(proto, {});
+ assertEquals(result.a, 1);
+ assertEquals(result.__proto__, proto);
+})()
« no previous file with comments | « test/cctest/test-code-stub-assembler.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698