This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
utf8_heavy.pl: Change data structure for in-lined definitions
authorKarl Williamson <public@khwilliamson.com>
Tue, 18 Mar 2014 17:43:59 +0000 (11:43 -0600)
committerKarl Williamson <public@khwilliamson.com>
Tue, 18 Mar 2014 18:51:23 +0000 (12:51 -0600)
commit3854b4b8c7222f0112e93a0e5dd89abcb5f7518e
tree2d260c881cb0f3f001e3d516b160610b28271b15
parentb72d82dc1770487df30e3939e26d423334f3f6aa
utf8_heavy.pl: Change data structure for in-lined definitions

This commit puts the in-lined definitions introduced by
eb0925341cc65ce6ce57503ec0ab97cdad39dc98 into a separate array,
where each element is a unique definition.  This can result in slightly
smaller current memory usage in utf8_heavy.pl, as the strings giving the
file names now only appear once, and what replaces them in the hash
values are strings of digits indices, which are shorter.

But doing this allows us in a later commit to increase the number of
ranges in the tables that get in-lined, without increasing memory usage.

This commit also changes the code that generates the definitions to be
more general, so that it becomes trivial to change things to generate
in-line definitions for tables with more than one range.
lib/Unicode/UCD.t
lib/unicore/mktables
lib/utf8_heavy.pl