develooper Front page | perl.perl5.porters | Postings from June 2013

Re: [perl #118297] perlbug AutoReply: Mixing up- and down-gradedstrings in regex broken in 5.18.0

From:
D. Ilmari Mannsåker
Date:
June 4, 2013 18:59
Subject:
Re: [perl #118297] perlbug AutoReply: Mixing up- and down-gradedstrings in regex broken in 5.18.0
Message ID:
51AE0E1C.8010508@net-a-porter.com
More specifically, the error occurs when a variable containing a 
downgraded non-ASCII string is interpolated in a regex after an upgraded 
one.

This doesn't warn:

   $ perl -e 'utf8::upgrade(my $u = "\x{e5}"); utf8::downgrade(my $d = 
"\x{e5}"); qr{$d $u}'

Nor does this:

   $ perl -e 'utf8::downgrade(my $d = "\x{e5}"); qr{\x{666} $d}'

-- 
ilmari

NET-A-PORTER.COM 
Irresistible fashion at your fingertips



CONFIDENTIALITY NOTICE
The information in this email is confidential and is intended solely for the addressee. Access to this email by anyone else is unauthorised. If you are not the intended recipient, you must not read, use or disseminate the information. Any views expressed in this message are those of the individual sender, except where the sender specifically states them to be the views of Net-A-Porter Group Limited. 

The Net-A-Porter Group Limited is a company registered in England & Wales Number: 3820604 Registered Office: 1 The Village Offices, Westfield, Ariel Way, London, W12 7GF



nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About