Skip to content
Snippets Groups Projects
Commit 490b2dc4 authored by André Bargull's avatar André Bargull
Browse files

Remove manual tests for 'yield' in generators

parent 36a8672a
No related branches found
No related tags found
No related merge requests found
// Copyright (C) 2013 the V8 project authors. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
/*---
description: >
`yield` is a reserved keyword within generator function bodies and may
not be used as a binding identifier.
es6id: 12.1.1
negative:
phase: early
type: SyntaxError
---*/
var g = function*() {
yield = 1;
};
// Copyright (C) 2013 the V8 project authors. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
/*---
description: >
`yield` is a reserved keyword within generator function bodies and may
not be used as a label.
es6id: 12.1.1
negative:
phase: early
type: SyntaxError
---*/
var g = function*() {
yield: 1;
};
// Copyright (C) 2013 the V8 project authors. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
/*---
description: >
`yield` is a reserved keyword within generator function bodies and may
not be used as a binding identifier.
features: [generators]
es6id: 12.1.1
negative:
phase: early
type: SyntaxError
---*/
var obj = {
*g() {
yield = 1;
}
};
// Copyright (C) 2013 the V8 project authors. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
/*---
description: >
`yield` is a reserved keyword within generator function bodies and may
not be used as a label.
features: [generators]
es6id: 12.1.1
negative:
phase: early
type: SyntaxError
---*/
var obj = {
*g() {
yield: 1;
}
};
// Copyright (C) 2013 the V8 project authors. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
/*---
description: >
`yield` is a reserved keyword within generator function bodies and may
not be used as a binding identifier.
features: [generators]
es6id: 12.1.1
negative:
phase: early
type: SyntaxError
---*/
class A {
*g() {
yield = 1;
}
}
// Copyright (C) 2013 the V8 project authors. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
/*---
description: >
`yield` is a reserved keyword within generator function bodies and may
not be used as a label.
features: [generators]
es6id: 12.1.1
negative:
phase: early
type: SyntaxError
---*/
class A {
*g() {
yield: 1;
}
}
// Copyright (C) 2013 the V8 project authors. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
/*---
description: >
`yield` is a reserved keyword within generator function bodies and may
not be used as a binding identifier.
es6id: 12.1.1
negative:
phase: early
type: SyntaxError
---*/
var result;
function* g() {
yield = 1;
}
result = g().next();
assert.sameValue(result.value, undefined);
assert.sameValue(result.done, true);
// Copyright (C) 2013 the V8 project authors. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
/*---
description: >
`yield` is a reserved keyword within generator function bodies and may
not be used as a label.
es6id: 12.1.1
negative:
phase: early
type: SyntaxError
---*/
function* g() {
yield: 1;
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment