develooper Front page | perl.perl5.porters | Postings from December 2017

Re: Revisiting smart match

Thread Previous | Thread Next
From:
Rocco Caputo
Date:
December 20, 2017 01:55
Subject:
Re: Revisiting smart match
Message ID:
1029B7F7-BB08-4823-8103-9B1353206AC2@pobox.com
> On Dec 19, 2017, at 03:49, Konovalov, Vadim <Vadim.Konovalov@dell.com> wrote:
> 
> > From: Leon Timmermans
>  
> > I think we're approaching this the wrong way.


I tossed around some ideas last night in IRC, but they were all flawed in one way or another.

Stepping back, I think most people are trying to fill this template:

"considering" SUBJECT {
  "if it's true that" CONDITION { ... }
  "if the thing being considered matches" MATCHER { ... }

  # and

  do { ... } "if it's true that" CONDITION;
  do { ... } "if the thing being considered matches" MATCHER;
}

Given the amount of effort that's been put into finding a succinct solution, maybe it's not possible in English.  It may be worth thinking about different templates entirely, or relaxing the "succinct" or "English" constraints.

As a language, English has no shame.  It won't mind if Perl ganks a few more words from elsewhere.

I don't recall seeing the problem expressed this way.  Sorry if it was and I missed it.  I hope someone finds this useful.

-- 
Rocco Caputo <rcaputo@pobox.com>

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