Skip to content

Commit 3d2b3e3

Browse files
JLHwungmathiasbynens
authored andcommitted
Use PropList-3.1.1 for Unicode 3.1.1
Unicode 3.1.1 published an updated PropList-3.1.1.txt, but the resources reused PropList-3.1.0.txt. The update removes the mathematical digits 1D7CE..1D7FF from Hex_Digit and adds ASCII_Hex_Digit, so Unicode 3.1.1 had the wrong Hex_Digit set and no ASCII_Hex_Digit. Assisted-By: Claude Opus 5.5 Issue: #110
1 parent dbe4426 commit 3d2b3e3

3 files changed

Lines changed: 26 additions & 5 deletions

File tree

‎data/3.1.1-properties.txt‎

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
# PropList-3.1.0.txt
1+
# PropList-3.1.1.txt
22
#
33
# Unicode Character Database: Extended Properties
44
# For documentation, see PropList.html
5-
# Date: 2001-03-02 00:06:33.9 GMT [MD]
5+
# Date: 2001-07-12 14:15:00.0 PDT [KW]
66
# Note: Unassigned and Noncharacter codepoints are omitted,
77
# except when listing Noncharacter or Cn.
88
# ================================================
@@ -243,9 +243,16 @@ FF5D ; Other_Math # Pe FULLWIDTH RIGHT CURLY BRACKET
243243
FF10..FF19 ; Hex_Digit # Nd [10] FULLWIDTH DIGIT ZERO..FULLWIDTH DIGIT NINE
244244
FF21..FF26 ; Hex_Digit # L& [6] FULLWIDTH LATIN CAPITAL LETTER A..FULLWIDTH LATIN CAPITAL LETTER F
245245
FF41..FF46 ; Hex_Digit # L& [6] FULLWIDTH LATIN SMALL LETTER A..FULLWIDTH LATIN SMALL LETTER F
246-
1D7CE..1D7FF ; Hex_Digit # Nd [50] MATHEMATICAL BOLD DIGIT ZERO..MATHEMATICAL MONOSPACE DIGIT NINE
247246

248-
# Total code points: 94
247+
# Total code points: 44
248+
249+
# ================================================
250+
251+
0030..0039 ; ASCII_Hex_Digit # Nd [10] DIGIT ZERO..DIGIT NINE
252+
0041..0046 ; ASCII_Hex_Digit # L& [6] LATIN CAPITAL LETTER A..LATIN CAPITAL LETTER F
253+
0061..0066 ; ASCII_Hex_Digit # L& [6] LATIN SMALL LETTER A..LATIN SMALL LETTER F
254+
255+
# Total code points: 22
249256

250257
# ================================================
251258

‎data/resources.mjs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ const resources = [
8484
main: 'https://unicode.org/Public/3.1-Update/UnicodeData-3.1.0.txt',
8585
scripts: 'https://unicode.org/Public/3.1-Update/Scripts-3.1.0.txt',
8686
blocks: 'https://unicode.org/Public/3.1-Update/Blocks-4.txt',
87-
properties: 'https://unicode.org/Public/3.1-Update/PropList-3.1.0.txt',
87+
properties: 'https://unicode.org/Public/3.1-Update1/PropList-3.1.1.txt',
8888
'derived-core-properties':
8989
'https://unicode.org/Public/3.1-Update/DerivedCoreProperties-3.1.0.txt',
9090
'derived-general-category':

‎tests/parsers.mjs‎

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -387,6 +387,20 @@ test('Historical Script values use canonical names', async (t) => {
387387
}
388388
});
389389

390+
test('Unicode 3.1.1 uses its corrected property list', async (t) => {
391+
const v310 = await parseProperties('3.1.0');
392+
const v311 = await parseProperties('3.1.1');
393+
t.assert.ok(v310.Hex_Digit.contains(0x1d7ce));
394+
t.assert.equal(v310.ASCII_Hex_Digit, undefined);
395+
t.assert.ok(!v311.Hex_Digit.contains(0x1d7ce));
396+
t.assert.ok(!v311.Hex_Digit.contains(0x1d7ff));
397+
t.assert.ok(v311.Hex_Digit.contains(0xff21));
398+
t.assert.deepEqual(
399+
v311.ASCII_Hex_Digit.toArray(),
400+
[...'0123456789ABCDEFabcdef'].map((c) => c.codePointAt(0)),
401+
);
402+
});
403+
390404
test('Legacy property ranges preserve six-digit code points', async (t) => {
391405
const properties = await parseProperties('3.0.1');
392406
t.assert.ok(properties.Private_Use.contains(0x100000));

0 commit comments

Comments
 (0)