summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/generators/yield-yield.js
blob: 123abc5b77574a2a8747e758a6dfd90fbde65f48 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
// Bug 880447

load(libdir + "asserts.js");

function f() {
    yield yield 1;
}

var g = f();
assertEq(g.next(), 1);
assertEq(g.send("hello"), "hello");
assertThrowsValue(() => g.next(), StopIteration);