Skip Menu |
Report information
Id: 130125
Status: resolved
Priority: 0/
Queue: perl6

Owner: Nobody
Requestors: alex.jakimenko [at] gmail.com
Cc:
AdminCc:

Severity: (no value)
Tag: regex
Platform: (no value)
Patch Status: (no value)
VM: (no value)



Date: Fri, 18 Nov 2016 00:14:07 +0200
To: rakudobug [...] perl.org
From: Aleks-Daniel Jakimenko-Aleksejev <alex.jakimenko [...] gmail.com>
Subject: [REGEX] negative numbers in ranges are understood incorrectly (/ .**{-10..-5} /)
Download (untitled) / with headers
text/plain 109b
Code:
say ‘abcefghij’ ~~ / .**{-10..-5} /

Result:
「abcefghij」

I think it should match nothing.
On 2016-11-17 14:14:25, alex.jakimenko@gmail.com wrote:
Show quoted text
> *Code:*
> say ‘abcefghij’ ~~ / .**{-10..-5} /
>
> *Result:*
> 「abcefghij」
>
> I think it should match nothing.


Same behavior with something like {10..0}, probably the same bug.
RT-Send-CC: perl6-compiler [...] perl.org
Download (untitled) / with headers
text/plain 362b
On Thu, 17 Nov 2016 14:14:25 -0800, alex.jakimenko@gmail.com wrote: Show quoted text
> *Code:* > say ‘abcefghij’ ~~ / .**{-10..-5} / > > *Result:* > 「abcefghij」 > > I think it should match nothing.
Thank you for the report. This is now fixed. Fix: https://github.com/rakudo/rakudo/commit/681d6be9742e7c0 Test: https://github.com/perl6/roast/commit/99c822abdeefbbaf0


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

For issues related to this RT instance (aka "perlbug"), please contact perlbug-admin at perl.org