This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
toke.c: Keep better track for avoiding work in tr///
As explained in the comments, tr/// creates byte map tables for bytes
0-255 if everything is below 256. If something is higher than that,
special handling is required (currently a swash), and so there is no
point in creating the tables here by expanding each range. Prior to
this commit, it realized this on a per-range basis, not expanding ranges
which extend above 255. This commit changes that so if any time it
finds something above 255, it remembers that and skips the expansion of
all future ranges encountered.
This was done without adding any extra tests outside the specific tr///
code.