test262/test/language/comments/hashbang/eval.js

17 lines
465 B
JavaScript
Raw Normal View History

// Copyright (C) 2019 Leo Balter. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
2018-12-03 22:55:42 +01:00
/*---
esid: pending
description: >
Hashbang comments should be available in Script evaluator contexts. (direct eval)
2018-12-03 22:55:42 +01:00
info: |
HashbangComment::
#! SingleLineCommentChars[opt]
2019-02-05 18:46:27 +01:00
features: [hashbang]
2018-12-03 22:55:42 +01:00
---*/
assert.sameValue(eval('#!\n'), undefined);
2019-02-05 18:46:27 +01:00
assert.sameValue(eval('#!\n1'), 1)
assert.sameValue(eval('#!2\n'), undefined);