Re: [Pre-RFC Discussion] User Defined Operator Overloads (again)
| From: | Jordan LeDoux | Date: | Mon, 16 Sep 2024 17:51:04 +0000 |
| Subject: | Re: [Pre-RFC Discussion] User Defined Operator Overloads (again) | ||
| References: | 1 2 3 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-125569@lists.php.net to get a copy of this message | ||
On Mon, Sep 16, 2024 at 6:52 AM Bilge <bilge@scriptfusion.com> wrote:
>
>
> On Mon, 16 Sept 2024, 15:28 someniatko, <someniatko@gmail.com> wrote:
>
>> On behalf of all struggling PHP developers who would like to implement
>> patterns like Value Objects, with custom equality criterias
>>
>
> I seriously doubt anyone is struggling without this, unless you care to
> provide proof to the contrary. I think this is "nice to have" at best, and
> in that regard, probably disproporional to the effort required to support
> it.
>
> Cheers,
> Bilge
>
Perhaps. I would like to point out that (somewhat to my surprise) the PHP
reddit thread about my original RFC which was declined had about 2/3
community approval in the straw poll:
https://www.reddit.com/poll/rv11fc
I do not disagree that operator overloads as a feature is a specific tool
for a specific problem, and people can ALWAYS make method calls instead of
use operators. But it seems clear to me that there are a great many
developers who feel the feature will help them write more
understandable/maintainable/capable code. The people "struggling" without
this are people trying to develop extremely technical and niche libraries
(like myself). It is a "nice to have" for most people, but I do not believe
that diminishes the number of developers I've talked with before and after
my previous RFC who were wanting this feature.
Jordan