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

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

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



Subject: [REGRESSION] [LTA] Trying to put an infinite range into a native array no longer throws (my int @a = ^Inf)
Download (untitled) / with headers
text/plain 461b
Code: my int @a = ^Inf; dd @a Result (2015.12,2016.02): This type cannot unbox to a native integer in block <unit> at /tmp/fdFVh_0R7j line 1 Result (2016.03,HEAD): array[int].new() In other words, ^Inf does nothing when assigned to @a. Even though the previous error message was LTA, the behavior was better because it wasn't swallowing it silently. Bisectable points to https://github.com/rakudo/rakudo/commit/2a20197e8ffbc7e0f6ff80794509ee14db93c368
RT-Send-CC: perl6-compiler [...] perl.org
Download (untitled) / with headers
text/plain 1.2k
The problem is the operator returns a failure, but since we're assigning it doesn't get sunk and so is silent. I see 16 fail()s in src/core/native_array.pm and I'm unsure what the best way to do this (lizmat, any idea?) Along with the silent one for STORE, the .splice ones also explode prematurely by being stuffed into a native type somewhere: my int @a = ^Inf; # Failure is silent my int @a; @a.append: 1...*; # Failure explodes my int @a; @a.unshift: 1...*; # Failure explodes my int @a; @a.splice: 1...*; # Failure, gives: <camelia> rakudo-moar 19df35: OUTPUT«This type cannot unbox to a native integer: P6opaque, Failure␤ in block <unit> at <tmp> line 1␤␤» On Thu, 29 Dec 2016 09:33:20 -0800, alex.jakimenko@gmail.com wrote: Show quoted text
> Code: > my int @a = ^Inf; dd @a > > > Result (2015.12,2016.02): > This type cannot unbox to a native integer > in block <unit> at /tmp/fdFVh_0R7j line 1 > > > Result (2016.03,HEAD): > array[int].new() > > > > In other words, ^Inf does nothing when assigned to @a. Even though the > previous error message was LTA, the behavior was better because it > wasn't swallowing it silently. > > Bisectable points to > https://github.com/rakudo/rakudo/commit/2a20197e8ffbc7e0f6ff80794509ee14db93c368
*operation .oO( where's the edit button when you need it /o\ )
Subject: Re: [perl #130443] [REGRESSION] [LTA] Trying to put an infinite range into a native array no longer throws (my int @a = ^Inf)
To: Carl Mäsak via RT <perl6-bugs-followup [...] perl.org>
Date: Thu, 29 Dec 2016 13:47:12 -0500
From: Brandon Allbery <allbery.b [...] gmail.com>
CC: perl6-compiler <perl6-compiler [...] perl.org>
Download (untitled) / with headers
text/plain 581b

On Thu, Dec 29, 2016 at 1:43 PM, Zoffix Znet via RT <perl6-bugs-followup@perl.org> wrote:
Show quoted text
I see 16 fail()s in src/core/native_array.pm and I'm unsure what the best way to do this (lizmat, any idea?)

Is this making moritz's point on IRC yesterday?
2016 Dec 28 18:39:27 <moritz> I think fail() was a mistake, and it's time we admitted it

--
brandon s allbery kf8nh                               sine nomine associates
allbery.b@gmail.com                                  ballbery@sinenomine.net
unix, openafs, kerberos, infrastructure, xmonad        http://sinenomine.net
Subject: Re: [perl #130443] [REGRESSION] [LTA] Trying to put an infinite range into a native array no longer throws (my int @a = ^Inf)
From: Elizabeth Mattijsen <liz [...] dijkmat.nl>
Date: Thu, 29 Dec 2016 22:11:47 +0100
To: "Aleks-Daniel Jakimenko-Aleksejev (via RT)" <perl6-bugs-followup [...] perl.org>
Download (untitled) / with headers
text/plain 890b
Fixed with aa35065, tests needed. Show quoted text
> On 29 Dec 2016, at 18:33, Aleks-Daniel Jakimenko-Aleksejev (via RT) <perl6-bugs-followup@perl.org> wrote: > > # New Ticket Created by Aleks-Daniel Jakimenko-Aleksejev > # Please include the string: [perl #130443] > # in the subject line of all future correspondence about this issue. > # <URL: https://rt.perl.org/Ticket/Display.html?id=130443 > > > > Code: > my int @a = ^Inf; dd @a > > > Result (2015.12,2016.02): > This type cannot unbox to a native integer > in block <unit> at /tmp/fdFVh_0R7j line 1 > > > Result (2016.03,HEAD): > array[int].new() > > > > In other words, ^Inf does nothing when assigned to @a. Even though the previous error message was LTA, the behavior was better because it wasn't swallowing it silently. > > Bisectable points to https://github.com/rakudo/rakudo/commit/2a20197e8ffbc7e0f6ff80794509ee14db93c368
RT-Send-CC: perl6-compiler [...] perl.org
Download (untitled) / with headers
text/plain 376b
On Thu, 29 Dec 2016 10:47:39 -0800, allbery.b@gmail.com wrote: Show quoted text
> On Thu, Dec 29, 2016 at 1:43 PM, Zoffix Znet via RT < > perl6-bugs-followup@perl.org> wrote:
Show quoted text
> Is this making moritz's point on IRC yesterday?
By that logic we should be throwing away all the features, the first time we encounter a buggy interaction. https://irclog.perlgeek.de/perl6-dev/2016-12-28#i_13814034


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