develooper Front page | perl.perl5.porters | Postings from February 2022

quoting with bidi bracketing characters

Thread Next
Ricardo Signes
February 3, 2022 03:43
quoting with bidi bracketing characters
Message ID:

A mere seven and a half years ago, I said it would be nice to get more bracketing pairs available in non-ASCII source.  Here's the message:

I still think we should do this.

Unicode provides a thing called bracket pairs <>.  These are pairs of characters that have an opening and a closing character and can enclose a run of other characters.  Each pair has an opening and closing character.  I think that when processing utf-8 source (under "use utf8") we could treat these pairs as paired delimiters for quote-like operators.  For example
my @words = qw〔 bingo bango bongo 〕;

To match the behavior of ASCII brackets, these would nest.
my $string = q⌜This string contains ⌜ and ⌟ which is fine.⌟;

I can write this up as an RFC if there's general interest.

Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About