summaryrefslogtreecommitdiffstats
path: root/js/src/tests/non262/reflect-parse/generators.js
blob: 14bac5b52703d4ab28564d91f761b3a90ec959e5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
// |reftest| skip-if(!xulRuntime.shell)
function test() {

// generators

assertDecl("function* gen() {}", genFunDecl("es6", ident("gen"), [], blockStmt([])));
assertExpr("(function*() {})", genFunExpr("es6", null, [], blockStmt([])));
assertExpr("(function* gen() {})", genFunExpr("es6", ident("gen"), [], blockStmt([])));

}

runtest(test);