Skip Menu |
Report information
Id: 128418
Status: open
Priority: 0/
Queue: perl6

Owner: Nobody
Requestors: cpan [at] zoffix.com
Cc:
AdminCc:

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



Subject: [RFC] Deprecate eval-dies-ok/eval-lives-ok in favour of Str arg to dies-ok/lives-ok
Download (untitled) / with headers
text/plain 492b
In Test.pm6, we have throws-like that takes either a Callable or a Str as the first arg. The Callable gets called and Str gets EVALed. However, with dies-ok/lives-ok the implementation rolls out an entirely new set of subs: eval-dies-ok/eval-lives-ok. This RFC proposes the eval-dies-ok/eval-lives-ok subs get deprecated and eventually removed in favour of implementing an interface consistent with throws-like where dies-ok/lives-ok will take either Callable or Str and Str will get EVALed
To: "Zoffix Znet (via RT)" <perl6-bugs-followup [...] perl.org>
Subject: Re: [perl #128418] [RFC] Deprecate eval-dies-ok/eval-lives-ok in favour of Str arg to dies-ok/lives-ok
From: Elizabeth Mattijsen <liz [...] dijkmat.nl>
Date: Thu, 16 Jun 2016 13:13:25 -0400
Download (untitled) / with headers
text/plain 1.1k
Show quoted text
> On 16 Jun 2016, at 13:08, Zoffix Znet (via RT) <perl6-bugs-followup@perl.org> wrote: > > # New Ticket Created by Zoffix Znet > # Please include the string: [perl #128418] > # in the subject line of all future correspondence about this issue. > # <URL: https://rt.perl.org/Ticket/Display.html?id=128418 > > > > In Test.pm6, we have throws-like that takes either a Callable or a Str as the first arg. The Callable gets called and Str gets EVALed. > > However, with dies-ok/lives-ok the implementation rolls out an entirely new set of subs: eval-dies-ok/eval-lives-ok. > > This RFC proposes the eval-dies-ok/eval-lives-ok subs get deprecated and eventually removed in favour of implementing an interface consistent with throws-like where dies-ok/lives-ok will take either Callable or Str and Str will get EVALed
I’m all for that. However, before XMas, as far as I remember, jnthn has been busy removing throws-like for dies-ok, because the throws-like were too specific. The reason for this change was really never clear to me, and/or my memory of those tension-filled days is too hazy. What I’m saying is, before going on with this, check with jnthn / TimToady. Liz
From: Will Coleda <will [...] coleda.com>
Subject: Re: [perl #128418] [RFC] Deprecate eval-dies-ok/eval-lives-ok in favour of Str arg to dies-ok/lives-ok
To: Elizabeth Mattijsen <liz [...] dijkmat.nl>
Date: Mon, 20 Jun 2016 08:16:34 -0400
CC: "Zoffix Znet (via RT)" <perl6-bugs-followup [...] perl.org>
Download (untitled) / with headers
text/plain 2.6k
This was discussed briefly on irc recently, but I wanted to sum up what happened, as I recall. There were 2 competing issues here: One was lizmat's changes to insure that a very specific exception was occurring, so that we could ensure that a test was not "just" dying, but was throwing a specific exception type - but we didn't have time to "spec"-ify the types, so in a lot of cases, an AdHoc type was used. The second was jnthn's changes to avoid checking for a very specific exception type when we hadn't actually "spec"-ified that type. If this change hadn't gone in, we would have put in the 6.c roast tests a test for a very specific exception type that was only a placeholder, and then have been unable to change that type to an appropriate type until the next spec round. The ideal would have been to find every place we had one of the AdHoc exception types, determine what the appropriate, (probably new) specific type was in that instance, and update rakudo and roast; A fallback might have been to explicitly declare that any AdHoc exception types were placeholders and subject to change. We just ended up running out of time leading up to Christmas to solve both issues simultaneously. We still have time to fix this issue properly before 6.d; But we can consider taking the fallback approach this time if we have to. On Thu, Jun 16, 2016 at 1:13 PM, Elizabeth Mattijsen <liz@dijkmat.nl> wrote: Show quoted text
>
>> On 16 Jun 2016, at 13:08, Zoffix Znet (via RT) <perl6-bugs-followup@perl.org> wrote: >> >> # New Ticket Created by Zoffix Znet >> # Please include the string: [perl #128418] >> # in the subject line of all future correspondence about this issue. >> # <URL: https://rt.perl.org/Ticket/Display.html?id=128418 > >> >> >> In Test.pm6, we have throws-like that takes either a Callable or a Str as the first arg. The Callable gets called and Str gets EVALed. >> >> However, with dies-ok/lives-ok the implementation rolls out an entirely new set of subs: eval-dies-ok/eval-lives-ok. >> >> This RFC proposes the eval-dies-ok/eval-lives-ok subs get deprecated and eventually removed in favour of implementing an interface consistent with throws-like where dies-ok/lives-ok will take either Callable or Str and Str will get EVALed
> > I’m all for that. > > However, before XMas, as far as I remember, jnthn has been busy removing throws-like for dies-ok, because the throws-like were too specific. > > The reason for this change was really never clear to me, and/or my memory of those tension-filled days is too hazy. What I’m saying is, before going on with this, check with jnthn / TimToady. > > > > Liz
-- Will "Coke" Coleda


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