Script_-_Bengali.js (2060B)
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 Unicode property escapes for `Script=Bengali` 8 info: | 9 Generated by https://github.com/mathiasbynens/unicode-property-escapes-tests 10 Unicode v17.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 0x0009B2, 19 0x0009D7 20 ], 21 ranges: [ 22 [0x000980, 0x000983], 23 [0x000985, 0x00098C], 24 [0x00098F, 0x000990], 25 [0x000993, 0x0009A8], 26 [0x0009AA, 0x0009B0], 27 [0x0009B6, 0x0009B9], 28 [0x0009BC, 0x0009C4], 29 [0x0009C7, 0x0009C8], 30 [0x0009CB, 0x0009CE], 31 [0x0009DC, 0x0009DD], 32 [0x0009DF, 0x0009E3], 33 [0x0009E6, 0x0009FE] 34 ] 35 }); 36 testPropertyEscapes( 37 /^\p{Script=Bengali}+$/u, 38 matchSymbols, 39 "\\p{Script=Bengali}" 40 ); 41 testPropertyEscapes( 42 /^\p{Script=Beng}+$/u, 43 matchSymbols, 44 "\\p{Script=Beng}" 45 ); 46 testPropertyEscapes( 47 /^\p{sc=Bengali}+$/u, 48 matchSymbols, 49 "\\p{sc=Bengali}" 50 ); 51 testPropertyEscapes( 52 /^\p{sc=Beng}+$/u, 53 matchSymbols, 54 "\\p{sc=Beng}" 55 ); 56 57 const nonMatchSymbols = buildString({ 58 loneCodePoints: [ 59 0x000984, 60 0x0009A9, 61 0x0009B1, 62 0x0009DE 63 ], 64 ranges: [ 65 [0x00DC00, 0x00DFFF], 66 [0x000000, 0x00097F], 67 [0x00098D, 0x00098E], 68 [0x000991, 0x000992], 69 [0x0009B3, 0x0009B5], 70 [0x0009BA, 0x0009BB], 71 [0x0009C5, 0x0009C6], 72 [0x0009C9, 0x0009CA], 73 [0x0009CF, 0x0009D6], 74 [0x0009D8, 0x0009DB], 75 [0x0009E4, 0x0009E5], 76 [0x0009FF, 0x00DBFF], 77 [0x00E000, 0x10FFFF] 78 ] 79 }); 80 testPropertyEscapes( 81 /^\P{Script=Bengali}+$/u, 82 nonMatchSymbols, 83 "\\P{Script=Bengali}" 84 ); 85 testPropertyEscapes( 86 /^\P{Script=Beng}+$/u, 87 nonMatchSymbols, 88 "\\P{Script=Beng}" 89 ); 90 testPropertyEscapes( 91 /^\P{sc=Bengali}+$/u, 92 nonMatchSymbols, 93 "\\P{sc=Bengali}" 94 ); 95 testPropertyEscapes( 96 /^\P{sc=Beng}+$/u, 97 nonMatchSymbols, 98 "\\P{sc=Beng}" 99 ); 100 101 reportCompare(0, 0);