2015-12-15 17:33:49 +01:00
|
|
|
// Copyright (C) 2015 André Bargull. All rights reserved.
|
|
|
|
// This code is governed by the BSD license found in the LICENSE file.
|
|
|
|
|
|
|
|
/*---
|
2016-02-22 15:47:03 +01:00
|
|
|
esid: sec-generator-function-definitions-static-semantics-early-errors
|
2015-12-15 17:33:49 +01:00
|
|
|
description: >
|
|
|
|
A SyntaxError is thrown if a generator contains a non-simple parameter list and a UseStrict directive.
|
|
|
|
info: >
|
|
|
|
Static Semantics: Early Errors
|
|
|
|
|
|
|
|
It is a Syntax Error if ContainsUseStrict of GeneratorBody is true and IsSimpleParameterList of FormalParameters is false.
|
2016-01-31 00:57:28 +01:00
|
|
|
negative:
|
|
|
|
phase: early
|
|
|
|
type: SyntaxError
|
2015-12-15 17:33:49 +01:00
|
|
|
---*/
|
|
|
|
|
2017-04-29 22:31:08 +02:00
|
|
|
throw "Test262: This statement should not be evaluated.";
|
|
|
|
|
2015-12-15 17:33:49 +01:00
|
|
|
function* f(a = 0) {
|
|
|
|
"use strict";
|
|
|
|
}
|