>
> Better map/filter/reduce primitives in PHP would be dandy, but they have
> nothing to do with array grouping. They're a separate operation that should
> be composed with grouping. Packing them all into a single function sounds
> like a terrible idea.
>
> If we wanted that... that's called list
>
> Better map/filter/reduce primitives in PHP would be dandy, but they have
> nothing to do with array grouping. They're a separate operation that should
> be composed with grouping. Packing them all into a single function sounds
> like a terrible idea.
>
> If we wanted that... that's called list
Revision to my recommendation are:
1. signature:
array_group(
array|object $array,
int|string|array $index_key,
callable $reducer = null,
callable $mapper = null,
callable $filter = null,
callable $sorter = null,
): array
2. `sorter` should
On Mon, Dec 6, 2021, at 4:16 PM, Hendra Gunawan wrote:
>>
>> Hello Folks, Thanks a lot for your feedback, as already mentioned in
>> the RFC and as mentioned by Rowan too a new function is an option. I
>> think that mostly we will go with the new function option.
>> I will try to edit the PR to add
>
> Hello Folks, Thanks a lot for your feedback, as already mentioned in
> the RFC and as mentioned by Rowan too a new function is an option. I
> think that mostly we will go with the new function option.
> I will try to edit the PR to add a new function, does there any
> suggestions/naming convent
The named arguments are a great thing to set in mind, but I think that
we will go to complicate it with optional arguments.
there is a comment on the PR that asks for another option to preserve
the sub-array index to be the new array index. also with the comments
by `Hendra Gunawan` in mind. adding
On 05/12/2021 14:02, Rowan Tommins wrote:
Since this is explicitly an open question in the current RFC draft, it
seems a bit premature to talk about voting, rather than encouraging the
RFC to develop in a particular direction.
I hope it was taken as nothing more than an indication that adding
> Le 6 déc. 2021 à 09:44, Hassan Ahmed <7sno...@gmail.com> a écrit :
>
> Hello Folks, Thanks a lot for your feedback, as already mentioned in
> the RFC and as mentioned by Rowan too a new function is an option. I
> think that mostly we will go with the new function option.
> I will try to edit t
Hi Máté,
Le lun. 6 déc. 2021 à 10:00, Máté Kocsis a écrit :
>
> Hi Patrick,
>
>>
>> Thank you for those stats. Would you have the chance to have some data
>> including PHP 8.0 as well?
>> Because without PHP 8.0 data, we can't deduce anything about what PHP
>> 8.1 brings over PHP 8.0 and or 8.0 o
Hi Patrick,
> Thank you for those stats. Would you have the chance to have some data
> including PHP 8.0 as well?
> Because without PHP 8.0 data, we can't deduce anything about what PHP
> 8.1 brings over PHP 8.0 and or 8.0 over 7.4.
> Virtually, 8.1 may even be slower than 8.0 if the big increase
Hello Folks, Thanks a lot for your feedback, as already mentioned in
the RFC and as mentioned by Rowan too a new function is an option. I
think that mostly we will go with the new function option.
I will try to edit the PR to add a new function, does there any
suggestions/naming conventions for the
11 matches
Mail list logo