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

Unified Diff: test/mjsunit/es6/generators-iteration.js

Issue 1590873002: Make generators non-constructable. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Adapt test262.status Created 4 years, 11 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 | « src/runtime/runtime-generator.cc ('k') | test/mjsunit/es6/generators-objects.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/es6/generators-iteration.js
diff --git a/test/mjsunit/es6/generators-iteration.js b/test/mjsunit/es6/generators-iteration.js
index faeb68380fea4aa67a97ace057291d075e23a6c8..e61a7c3a9a5c8a44060ab5f380bc347c38291a19 100644
--- a/test/mjsunit/es6/generators-iteration.js
+++ b/test/mjsunit/es6/generators-iteration.js
@@ -101,9 +101,9 @@ function TestGenerator(g, expected_values_for_next,
testThrow(function*() { return yield* g(); });
if (g instanceof GeneratorFunction) {
- testNext(function() { return new g(); });
- testSend(function() { return new g(); });
- testThrow(function() { return new g(); });
+ testNext(g);
+ testSend(g);
+ testThrow(g);
}
}
@@ -259,18 +259,6 @@ TestGenerator(
[1, 2, undefined]);
TestGenerator(
- function g18() {
- function* g() { yield this.x; yield this.y; }
- var iter = new g;
- iter.x = 1;
- iter.y = 2;
- return iter;
- },
- [1, 2, undefined],
- "foo",
- [1, 2, undefined]);
-
-TestGenerator(
function* g19() {
var x = 1;
yield x;
« no previous file with comments | « src/runtime/runtime-generator.cc ('k') | test/mjsunit/es6/generators-objects.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698