develooper Front page | perl.perl5.porters | Postings from January 2022

Re: Things you can't do in a signatured sub

Thread Previous | Thread Next
From:
Alexander Hartmaier
Date:
January 21, 2022 07:12
Subject:
Re: Things you can't do in a signatured sub
Message ID:
CAB49Qrb_o05mrsZwOyR8c1YHqzxSK_D4ZKQxzovwkVH1FL7WPQ@mail.gmail.com
On Fri, Jan 21, 2022 at 4:07 AM Matthew Persico <matthew.persico@gmail.com>
wrote:

>
>
> On Thu, Jan 20, 2022 at 4:20 AM Alexander Hartmaier <
> alex.hartmaier@gmail.com> wrote:
>
>>
>> Seems I have missed the possibility to do that in perlsub (
>> https://perldoc.perl.org/perlsub#Signatures). Maybe because the very
>> first example which shows this special case is a complex one using lvalue
>> and its variable is called @c. I'd suggest to start with a simpler example
>> and have a dedicated one for that case which calls it @rest. (variables 'at
>> rest' ;-)
>>
>> Thanks to all your input I've now converted all subs to signatured subs
>> adding @ to the sig of all undocumented methods, just to be sure to not
>> cause an exception.
>>
>> As the docs are pretty long, sub-headings 😂 would help to quicker find
>> the correct example for ones use case.
>> If there is an agreement on this I'm willing to write patch.
>>
>
> My USD 0.02: I'd write the patch and submit it. Waiting for "permission"
> could take forever, but putting a concrete patch in front of people will
> get their attention.
>

I'm asking first to not waste my time as this happened before.

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