character-union-string-literal.js (827B)
1 // Copyright 2025 Mathias Bynens. All rights reserved. 2 // This code is governed by the BSD license found in the LICENSE file. 3 4 /*--- 5 author: Mathias Bynens 6 description: > 7 Extended character classes enabled by the RegExp `v` flag support 8 properties of strings, string literals, and set operations 9 info: | 10 Generated by https://github.com/mathiasbynens/unicode-property-escapes-tests 11 Unicode v17.0.0 12 esid: sec-patterns 13 features: [regexp-v-flag] 14 includes: [regExpUtils.js] 15 ---*/ 16 17 testExtendedCharacterClass({ 18 regExp: /^[_\q{0|2|4|9\uFE0F\u20E3}]+$/v, 19 expression: "[_\q{0|2|4|9\uFE0F\u20E3}]", 20 matchStrings: [ 21 "0", 22 "2", 23 "4", 24 "9\uFE0F\u20E3", 25 "_" 26 ], 27 nonMatchStrings: [ 28 "6\uFE0F\u20E3", 29 "7", 30 "C", 31 "\u2603", 32 "\u{1D306}", 33 "\u{1F1E7}\u{1F1EA}" 34 ], 35 }); 36 37 reportCompare(0, 0);