develooper Front page | perl.perl5.porters | Postings from May 2016

Re: [perl #128213] No deprecation warning on literal left curlybracket in /.{/ etc

Thread Previous | Thread Next
From:
demerphq
Date:
May 24, 2016 23:26
Subject:
Re: [perl #128213] No deprecation warning on literal left curlybracket in /.{/ etc
Message ID:
CANgJU+UBGw5LTLHfthO8fiv_8jGbkJ8R41XoyKi9EnSo7=v+Sg@mail.gmail.com
On 25 May 2016 at 01:06, Zefram <zefram@fysh.org> wrote:
> demerphq wrote:
>>$ perl -wle'qr/\A{10}/'
>>
>>Quantifier unexpected on zero-length expression in regex m/\A{10}/ at -e line 1.
>
> That's just a warning.  It does actually parse as I stated.

Yes, no argument there. My point was more that IMO it would not be
particularly unreasonable to forbid certain quantifiers on an
assertion.

IOW, I do consider use of a {min,max} quantifier on an assertion to be
exceptional, and I would not mind if we forbid it when min!=0 or
max!=1.

Yves

-- 
perl -Mre=debug -e "/just|another|perl|hacker/"

Thread Previous | Thread Next


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