Re: [RFC] Global functions any() and all() on iterables

From: Date: Thu, 03 Sep 2020 14:39:21 +0000
Subject: Re: [RFC] Global functions any() and all() on iterables
References: 1 2  Groups: php.internals 
Request: Send a blank email to internals+get-111821@lists.php.net to get a copy of this message
Do you think that it could be proxied too? I mean, optimize foreach (array_keys()...) syntax to not call array_keys() in fact, but a optimized version of foreach to handle key only. Em qui, 3 de set de 2020 11:36, Sara Golemon <pollita@php.net> escreveu: > On Mon, Aug 31, 2020 at 6:56 PM tyson andre <tysonandre775@hotmail.com> > wrote: > > > I've created an RFC for > > https://wiki.php.net/rfc/any_all_on_iterable > > > > > I've probably reached this thread too late, but I'm going to throw out my > old chestnut that these things don't belong in the engine. They belong in > userspace. > > 1. Instant forward compatibility (any version can run composer > install) > 2. Instant bug fixes and improvements (no waiting for the next minor > version of PHP) > 3. Better visibility from the JIT (not having to cross userspace/internals > border is good) > > And that's all I'm going to say because I'm pretty sure I've lost the > argument long ago, but here's my any/all/none (and other) methods from > years ago (IN USERSPACE!): > > https://github.com/phplang/generator/blob/master/src/iterable.php > > -Sara >

« previous php.internals (#111821) next »