This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
unicode_constants.pl: Refactor to catch more paired delims
Previously, only characters that Unicode included in its bidirectional
algorithm have been eligible to be found by this program to be mirrored
string delimiters.
This commit adds 5 quotation marker character pairs that
are omitted from the bidirectional algorithm, as most quotes are,
because, as the Standard says, their "directionality and pairing status
is less predictable than paired brackets."
But we're not particularly interested in those semantics, most string
delimiters will be selected only for their visual appearance.
Because they aren't in the bidi algorithm, there is no property that
maps one member of a pair to its mate. However, Two characters whose
names pair only by LEFT vs RIGHT are almost certainly a mirrored pair.
This doesn't catch all possibilities; future commits will expand the
ones caught.
The commit refactors things so as to make future commits easier which
look at even more delimiter possibilities.