| 1 |
// Copyright (C) 2016 the V8 project authors. All rights reserved. |
| 2 |
// This code is governed by the BSD license found in the LICENSE file. |
| 3 |
/*--- |
| 4 |
esid: sec-additional-syntax-string-literals |
| 5 |
es6id: B.1.2 |
| 6 |
description: > |
| 7 |
LegacyOctalEscapeSequence is not enabled in strict mode code (regardless of |
| 8 |
the presence of Annex B) |
| 9 |
info: | |
| 10 |
EscapeSequence :: |
| 11 |
CharacterEscapeSequence |
| 12 |
LegacyOctalEscapeSequence |
| 13 |
HexEscapeSequence |
| 14 |
UnicodeEscapeSequence |
| 15 |
|
| 16 |
LegacyOctalEscapeSequence :: |
| 17 |
OctalDigit [lookahead ∉ OctalDigit] |
| 18 |
ZeroToThree OctalDigit [lookahead ∉ OctalDigit] |
| 19 |
FourToSeven OctalDigit |
| 20 |
ZeroToThree OctalDigit OctalDigit |
| 21 |
|
| 22 |
ZeroToThree :: one of |
| 23 |
0 1 2 3 |
| 24 |
|
| 25 |
FourToSeven :: one of |
| 26 |
4 5 6 7 |
| 27 |
|
| 28 |
This definition of EscapeSequence is not used in strict mode or when |
| 29 |
parsing TemplateCharacter. |
| 30 |
flags: [onlyStrict] |
| 31 |
negative: |
| 32 |
phase: parse |
| 33 |
type: SyntaxError |
| 34 |
---*/ |
| 35 |
|
| 36 |
throw "Test262: This statement should not be evaluated."; |
| 37 |
|
| 38 |
'\1'; |