Debian Codegraph @

js/src/tests/test262/built-ins/RegExp/property-escapes/generated/Script_Extensions_-_Devanagari.js

raw
1 // Copyright 2024 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 Unicode property escapes for `Script_Extensions=Devanagari`
8 info: |
9 Generated by https://github.com/mathiasbynens/unicode-property-escapes-tests
10 Unicode v16.0.0
11 esid: sec-static-semantics-unicodematchproperty-p
12 features: [regexp-unicode-property-escapes]
13 includes: [regExpUtils.js]
14 ---*/
15
16 const matchSymbols = buildString({
17 loneCodePoints: [
18 0x0002BC,
19 0x0020F0
20 ],
21 ranges: [
22 [0x000900, 0x000952],
23 [0x000955, 0x00097F],
24 [0x001CD0, 0x001CF6],
25 [0x001CF8, 0x001CF9],
26 [0x00A830, 0x00A839],
27 [0x00A8E0, 0x00A8FF],
28 [0x011B00, 0x011B09]
29 ]
30 });
31 testPropertyEscapes(
32 /^\p{Script_Extensions=Devanagari}+$/u,
33 matchSymbols,
34 "\\p{Script_Extensions=Devanagari}"
35 );
36 testPropertyEscapes(
37 /^\p{Script_Extensions=Deva}+$/u,
38 matchSymbols,
39 "\\p{Script_Extensions=Deva}"
40 );
41 testPropertyEscapes(
42 /^\p{scx=Devanagari}+$/u,
43 matchSymbols,
44 "\\p{scx=Devanagari}"
45 );
46 testPropertyEscapes(
47 /^\p{scx=Deva}+$/u,
48 matchSymbols,
49 "\\p{scx=Deva}"
50 );
51
52 const nonMatchSymbols = buildString({
53 loneCodePoints: [
54 0x001CF7
55 ],
56 ranges: [
57 [0x00DC00, 0x00DFFF],
58 [0x000000, 0x0002BB],
59 [0x0002BD, 0x0008FF],
60 [0x000953, 0x000954],
61 [0x000980, 0x001CCF],
62 [0x001CFA, 0x0020EF],
63 [0x0020F1, 0x00A82F],
64 [0x00A83A, 0x00A8DF],
65 [0x00A900, 0x00DBFF],
66 [0x00E000, 0x011AFF],
67 [0x011B0A, 0x10FFFF]
68 ]
69 });
70 testPropertyEscapes(
71 /^\P{Script_Extensions=Devanagari}+$/u,
72 nonMatchSymbols,
73 "\\P{Script_Extensions=Devanagari}"
74 );
75 testPropertyEscapes(
76 /^\P{Script_Extensions=Deva}+$/u,
77 nonMatchSymbols,
78 "\\P{Script_Extensions=Deva}"
79 );
80 testPropertyEscapes(
81 /^\P{scx=Devanagari}+$/u,
82 nonMatchSymbols,
83 "\\P{scx=Devanagari}"
84 );
85 testPropertyEscapes(
86 /^\P{scx=Deva}+$/u,
87 nonMatchSymbols,
88 "\\P{scx=Deva}"
89 );
90
91 reportCompare(0, 0);