mirror of
https://github.com/tc39/test262.git
synced 2025-07-23 22:15:24 +02:00
Apply review feedback
- indirect eval - files renaming - space after comma
This commit is contained in:
parent
9558093416
commit
6e4b434586
13
test/language/comments/hashbang/eval-indirect.js
Normal file
13
test/language/comments/hashbang/eval-indirect.js
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
/*---
|
||||||
|
esid: pending
|
||||||
|
description: >
|
||||||
|
Hashbang comments should be available in Script evaluator contexts. (indirect eval)
|
||||||
|
info: |
|
||||||
|
HashbangComment::
|
||||||
|
#! SingleLineCommentChars[opt]
|
||||||
|
features: [hashbang]
|
||||||
|
---*/
|
||||||
|
|
||||||
|
assert.sameValue((0, eval)('#!\n'), undefined);
|
||||||
|
assert.sameValue((0, eval)('#!\n1'), 1)
|
||||||
|
assert.sameValue((0, eval)('#!2\n'), undefined);
|
@ -1,7 +1,7 @@
|
|||||||
/*---
|
/*---
|
||||||
esid: pending
|
esid: pending
|
||||||
description: >
|
description: >
|
||||||
Hashbang comments should be available in Script evaluator contexts.
|
Hashbang comments should be available in Script evaluator contexts. (direct eval)
|
||||||
info: |
|
info: |
|
||||||
HashbangComment::
|
HashbangComment::
|
||||||
#! SingleLineCommentChars[opt]
|
#! SingleLineCommentChars[opt]
|
||||||
|
@ -17,8 +17,8 @@ for (const ctor of [
|
|||||||
GeneratorFunction,
|
GeneratorFunction,
|
||||||
AsyncGeneratorFunction,
|
AsyncGeneratorFunction,
|
||||||
]) {
|
]) {
|
||||||
assert.throws(SyntaxError, () => ctor('#!\n_',''), `${ctor.name} Call argument`);
|
assert.throws(SyntaxError, () => ctor('#!\n_', ''), `${ctor.name} Call argument`);
|
||||||
assert.throws(SyntaxError, () => ctor('#!\n_'), `${ctor.name} Call body`);
|
assert.throws(SyntaxError, () => ctor('#!\n_'), `${ctor.name} Call body`);
|
||||||
assert.throws(SyntaxError, () => new ctor('#!\n_',''), `${ctor.name} Construct argument`);
|
assert.throws(SyntaxError, () => new ctor('#!\n_', ''), `${ctor.name} Construct argument`);
|
||||||
assert.throws(SyntaxError, () => new ctor('#!\n_'), `${ctor.name} Construct body`);
|
assert.throws(SyntaxError, () => new ctor('#!\n_'), `${ctor.name} Construct body`);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user