[fc-lang] Allow using ".." instead of "-" in ranges

Allows copying emoji-data.txt and other Unicode data files intact.
This commit is contained in:
Behdad Esfahbod 2017-08-02 15:31:15 +01:00
parent 1bb8e691bd
commit 9978203bf1
2 changed files with 6 additions and 1 deletions

View File

@ -174,6 +174,11 @@ scan (FILE *f, char *file, FcCharSetFreezer *freezer)
if (sscanf (line, "%x-%x", &start, &end) != 2)
fatal (file, lineno, "parse error");
}
else if (strstr (line, ".."))
{
if (sscanf (line, "%x..%x", &start, &end) != 2)
fatal (file, lineno, "parse error");
}
else
{
if (sscanf (line, "%x", &start) != 1)

View File

@ -28,7 +28,7 @@
#
0023 # 1.1 [1] (#) number sign
002A # 1.1 [1] (*) asterisk
0030-0039 # 1.1 [10] (0-9) digit zero-digit nine
0030..0039 # 1.1 [10] (0-9) digit zero-digit nine
00A9 # 1.1 [1] (©️) copyright
00AE # 1.1 [1] (®️) registered
203C # 1.1 [1] (‼️) double exclamation mark