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

Re: Pre-{Pre-RFC} - match/case syntax

Thread Previous | Thread Next
From:
Darren Duncan
Date:
June 27, 2022 20:36
Subject:
Re: Pre-{Pre-RFC} - match/case syntax
Message ID:
a1d1784b-e205-ae47-cf2b-9ded0523374b@darrenduncan.net
On 2022-06-27 2:14 a.m., Paul "LeoNerd" Evans wrote:
> On Mon, 27 Jun 2022 02:11:08 -0700
> Darren Duncan <darren@darrenduncan.net> wrote:
> 
>> This should be generic and configurable in the same way map/grep/sort
>> etc are.
> 
> I'm not sure I follow this bit. How are those configurable now?
> 
> Can you suggest some examples?

I mean that in the place where you had the "==" you can put a sub ref for an 
inline definition of a comparison function so users can make it behave any way 
they want, like how they write "sort <sub ref> <list>" etc, rather than the "==" 
being only substitutable with a small list of pre-defined operators. -- Darren 
Duncan

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