From 6b8bd307d29dcf39f22bd067db513952e68dc811 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Bargull?= <andre.bargull@gmail.com> Date: Fri, 8 Dec 2017 13:22:26 -0800 Subject: [PATCH] Test other-id-start/continue and vertical tilde in identifiers --- .../identifiers/other_id_continue-escaped.js | 37 +++++++++++++++++++ .../language/identifiers/other_id_continue.js | 37 +++++++++++++++++++ .../identifiers/other_id_start-escaped.js | 19 ++++++++++ test/language/identifiers/other_id_start.js | 19 ++++++++++ .../vertical-tilde-continue-escaped.js | 16 ++++++++ .../identifiers/vertical-tilde-continue.js | 16 ++++++++ .../vertical-tilde-start-escaped.js | 16 ++++++++ .../identifiers/vertical-tilde-start.js | 16 ++++++++ 8 files changed, 176 insertions(+) create mode 100644 test/language/identifiers/other_id_continue-escaped.js create mode 100644 test/language/identifiers/other_id_continue.js create mode 100644 test/language/identifiers/other_id_start-escaped.js create mode 100644 test/language/identifiers/other_id_start.js create mode 100644 test/language/identifiers/vertical-tilde-continue-escaped.js create mode 100644 test/language/identifiers/vertical-tilde-continue.js create mode 100644 test/language/identifiers/vertical-tilde-start-escaped.js create mode 100644 test/language/identifiers/vertical-tilde-start.js diff --git a/test/language/identifiers/other_id_continue-escaped.js b/test/language/identifiers/other_id_continue-escaped.js new file mode 100644 index 0000000000..48efba7757 --- /dev/null +++ b/test/language/identifiers/other_id_continue-escaped.js @@ -0,0 +1,37 @@ +// Copyright (C) 2017 André Bargull. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +id: sec-names-and-keywords +info: Test grandfathered characters of ID_Continue. +description: > + Grandfathered characters (Other_ID_Start + Other_ID_Continue) +---*/ + +// Other_ID_Start (Unicode 4.0) +var a\u2118; +var a\u212E; +var a\u309B; +var a\u309C; + +// Other_ID_Start (Unicode 9.0) +var a\u1885; +var a\u1886; + +// Other_ID_Continue (Unicode 4.1) +var a\u1369; +var a\u136A; +var a\u136B; +var a\u136C; +var a\u136D; +var a\u136E; +var a\u136F; +var a\u1370; +var a\u1371; + +// Other_ID_Continue (Unicode 5.1) +var a\u00B7; +var a\u0387; + +// Other_ID_Continue (Unicode 6.0) +var a\u19DA; diff --git a/test/language/identifiers/other_id_continue.js b/test/language/identifiers/other_id_continue.js new file mode 100644 index 0000000000..ebe7f3fca4 --- /dev/null +++ b/test/language/identifiers/other_id_continue.js @@ -0,0 +1,37 @@ +// Copyright (C) 2017 André Bargull. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +id: sec-names-and-keywords +info: Test grandfathered characters of ID_Continue. +description: > + Grandfathered characters (Other_ID_Start + Other_ID_Continue) +---*/ + +// Other_ID_Start (Unicode 4.0) +var a℘; // U+2118 +var aâ„®; // U+212E +var aã‚›; // U+309B +var aã‚œ; // U+309C + +// Other_ID_Start (Unicode 9.0) +var aᢅ; // U+1885 +var aᢆ; // U+1886 + +// Other_ID_Continue (Unicode 4.1) +var aá©; // U+1369 +var aáª; // U+136A +var aá«; // U+136B +var aá¬; // U+136C +var aá; // U+136D +var aá®; // U+136E +var aá¯; // U+136F +var aá°; // U+1370 +var aá±; // U+1371 + +// Other_ID_Continue (Unicode 5.1) +var a·; // U+00B7 +var a·; // U+0387 + +// Other_ID_Continue (Unicode 6.0) +var a᧚; // U+19DA diff --git a/test/language/identifiers/other_id_start-escaped.js b/test/language/identifiers/other_id_start-escaped.js new file mode 100644 index 0000000000..2173e0959f --- /dev/null +++ b/test/language/identifiers/other_id_start-escaped.js @@ -0,0 +1,19 @@ +// Copyright (C) 2017 André Bargull. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +id: sec-names-and-keywords +info: Test grandfathered characters of ID_Start. +description: > + Grandfathered characters (Other_ID_Start) +---*/ + +// Other_ID_Start (Unicode 4.0) +var \u2118; +var \u212E; +var \u309B; +var \u309C; + +// Other_ID_Start (Unicode 9.0) +var \u1885; +var \u1886; diff --git a/test/language/identifiers/other_id_start.js b/test/language/identifiers/other_id_start.js new file mode 100644 index 0000000000..04fcfa3608 --- /dev/null +++ b/test/language/identifiers/other_id_start.js @@ -0,0 +1,19 @@ +// Copyright (C) 2017 André Bargull. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +id: sec-names-and-keywords +info: Test grandfathered characters of ID_Start. +description: > + Grandfathered characters (Other_ID_Start) +---*/ + +// Other_ID_Start (Unicode 4.0) +var ℘; // U+2118 +var â„®; // U+212E +var ã‚›; // U+309B +var ã‚œ; // U+309C + +// Other_ID_Start (Unicode 9.0) +var ᢅ; // U+1885 +var ᢆ; // U+1886 diff --git a/test/language/identifiers/vertical-tilde-continue-escaped.js b/test/language/identifiers/vertical-tilde-continue-escaped.js new file mode 100644 index 0000000000..b7acc2786d --- /dev/null +++ b/test/language/identifiers/vertical-tilde-continue-escaped.js @@ -0,0 +1,16 @@ +// Copyright (C) 2017 André Bargull. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +id: sec-names-and-keywords +info: Test VERTICAL TILDE (U+2E2F) is not recognized as ID_Continue character. +description: > + VERTICAL TILDE is in General Category 'Lm' and [:Pattern_Syntax:]. +negative: + type: SyntaxError + phase: early +---*/ + +throw "Test262: This statement should not be evaluated."; + +var a\u2E2F; diff --git a/test/language/identifiers/vertical-tilde-continue.js b/test/language/identifiers/vertical-tilde-continue.js new file mode 100644 index 0000000000..ed07cd0291 --- /dev/null +++ b/test/language/identifiers/vertical-tilde-continue.js @@ -0,0 +1,16 @@ +// Copyright (C) 2017 André Bargull. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +id: sec-names-and-keywords +info: Test VERTICAL TILDE (U+2E2F) is not recognized as ID_Continue character. +description: > + VERTICAL TILDE is in General Category 'Lm' and [:Pattern_Syntax:]. +negative: + type: SyntaxError + phase: early +---*/ + +throw "Test262: This statement should not be evaluated."; + +var aⸯ; // U+2E2F diff --git a/test/language/identifiers/vertical-tilde-start-escaped.js b/test/language/identifiers/vertical-tilde-start-escaped.js new file mode 100644 index 0000000000..ee0f2fc44c --- /dev/null +++ b/test/language/identifiers/vertical-tilde-start-escaped.js @@ -0,0 +1,16 @@ +// Copyright (C) 2017 André Bargull. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +id: sec-names-and-keywords +info: Test VERTICAL TILDE (U+2E2F) is not recognized as ID_Start character. +description: > + VERTICAL TILDE is in General Category 'Lm' and [:Pattern_Syntax:]. +negative: + type: SyntaxError + phase: early +---*/ + +throw "Test262: This statement should not be evaluated."; + +var \u2E2F; diff --git a/test/language/identifiers/vertical-tilde-start.js b/test/language/identifiers/vertical-tilde-start.js new file mode 100644 index 0000000000..815a6654d8 --- /dev/null +++ b/test/language/identifiers/vertical-tilde-start.js @@ -0,0 +1,16 @@ +// Copyright (C) 2017 André Bargull. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +id: sec-names-and-keywords +info: Test VERTICAL TILDE (U+2E2F) is not recognized as ID_Start character. +description: > + VERTICAL TILDE is in General Category 'Lm' and [:Pattern_Syntax:]. +negative: + type: SyntaxError + phase: early +---*/ + +throw "Test262: This statement should not be evaluated."; + +var ⸯ; // U+2E2F -- GitLab