Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:91218 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 51610 invoked from network); 12 Feb 2016 12:49:51 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 12 Feb 2016 12:49:51 -0000 Authentication-Results: pb1.pair.com smtp.mail=bobwei9@hotmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=bobwei9@hotmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain hotmail.com designates 65.55.111.162 as permitted sender) X-PHP-List-Original-Sender: bobwei9@hotmail.com X-Host-Fingerprint: 65.55.111.162 blu004-omc4s23.hotmail.com Received: from [65.55.111.162] ([65.55.111.162:59371] helo=BLU004-OMC4S23.hotmail.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id E5/72-25203-CE4DDB65 for ; Fri, 12 Feb 2016 07:49:49 -0500 Received: from BLU436-SMTP43 ([65.55.111.135]) by BLU004-OMC4S23.hotmail.com over TLS secured channel with Microsoft SMTPSVC(7.5.7601.23008); Fri, 12 Feb 2016 04:49:45 -0800 X-TMN: [bFgJs2VtiH0S6vBpcHQPoqtlsRxJbvcz] X-Originating-Email: [bobwei9@hotmail.com] Message-ID: Content-Type: multipart/alternative; boundary="Apple-Mail=_7AA6343C-5867-4416-AE40-EF3475F6B175" MIME-Version: 1.0 (Mac OS X Mail 8.2 \(2070.6\)) In-Reply-To: Date: Fri, 12 Feb 2016 13:49:39 +0100 CC: Joe Watkins , Andrea Faulds , PHP internals References: <38.31.07203.2EB94B65@pb1.pair.com> <8E.1A.36326.338F8B65@pb1.pair.com> To: guilhermeblanco@gmail.com X-Mailer: Apple Mail (2.2070.6) X-OriginalArrivalTime: 12 Feb 2016 12:49:43.0032 (UTC) FILETIME=[D8152F80:01D16593] Subject: Re: [PHP-DEV] [RFC][VOTE] Allow specifying keys in list() From: bobwei9@hotmail.com (Bob Weinand) --Apple-Mail=_7AA6343C-5867-4416-AE40-EF3475F6B175 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Hmm, I have to disagree=E2=80=A6 1. Just as intuitive as the whole list() construct. I don=E2=80=99t see = where this particular addition adds any strangeness. For your readability/hard to read code problem I think the RFC is just = doing a bad formatting job: list("name" =3D> $this->name, "colour" =3D> $this->colour, "age" =3D> $this->age, "cuteness" =3D> $this->cuteness) =3D $attributes; Would be how I=E2=80=99d format that. Makes it pretty obvious which keys = are used (nice list from top to bottom) and makes it nicely visible what = the origin array is, it being very prominently on the right. And at that point (also that I only have to parse the origin array only = once) it presents a nice readability improvement. And the 3. point regarding future scope is irrelevant. It=E2=80=99s = something this RFC would make possible, but it by far doesn=E2=80=99t = mean that it will ever come - it=E2=80=99s just future scope. Ignore it. Hence I ultimately think this RFC is a good idea. Thanks, Bob > Am 9.2.2016 um 16:36 schrieb guilhermeblanco@gmail.com: >=20 > Here is my reasons for no: >=20 > 1- Non-intuitive behavior > 2- Hard to read code, takes more time to understand underlying = logic/flow > 3- YAANPI =3D> Yet Another Alternate Named Parameters Implementation = (when I > look at future scope) > 4- Most common usage form (first example) still forces you to type = almost > same amount of logic with less readability and little value >=20 > Regards, >=20 > On Tue, Feb 9, 2016 at 1:50 AM, Joe Watkins = wrote: >=20 >> Morning internalz, >>=20 >> As mentioned the future scope stuff is scary, but not enough on = it's >> own to vote no. >>=20 >> So I want to vote yes, but I'm just waiting to hear objections = from no >> voters, in case they thought of something I didn't ... >>=20 >> Cheers >> Joe >>=20 >> On Mon, Feb 8, 2016 at 8:18 PM, Andrea Faulds wrote: >>=20 >>> Hi again, >>>=20 >>> There's been a lot of No votes on this RFC, but I haven't received = much >>> feedback as to why. Would any of you mind sharing your reasons, if >>> possible? It would be helpful if I knew why people have voted = against it, >>> as then I might be able to modify the RFC to be more palatable, or >>> understand where I went wrong. >>>=20 >>> Thanks! >>>=20 >>>=20 >>> Andrea Faulds wrote: >>>=20 >>>> Hi everyone, >>>>=20 >>>> It's been more than two weeks since I first proposed this RFC, and >>>> there's no outstanding issues preventing moving towards a vote. = There's >>>> not yet a language specification patch, but that can be done later. >>>>=20 >>>> So, I'm opening the vote on this RFC today, 2016-02-05, and it'll = close >>>> the Sunday after next, 2016-02-14. The vote requires a 2/3 majority = as >>>> it's a language change. >>>>=20 >>>> The RFC page is here: https://wiki.php.net/rfc/list_keys >>>>=20 >>>> Happy voting! >>>>=20 >>>=20 >>>=20 >>> -- >>> Andrea Faulds >>> https://ajf.me/ >>>=20 >>> -- >>> PHP Internals - PHP Runtime Development Mailing List >>> To unsubscribe, visit: http://www.php.net/unsub.php >>>=20 >>>=20 >>=20 >=20 >=20 >=20 > --=20 > Guilherme Blanco > MSN: guilhermeblanco@hotmail.com > GTalk: guilhermeblanco > Toronto - ON/Canada Bob --Apple-Mail=_7AA6343C-5867-4416-AE40-EF3475F6B175--