Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:98030 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 48703 invoked from network); 29 Jan 2017 23:45:19 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 29 Jan 2017 23:45:19 -0000 Authentication-Results: pb1.pair.com smtp.mail=cmbecker69@gmx.de; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=cmbecker69@gmx.de; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmx.de designates 212.227.17.20 as permitted sender) X-PHP-List-Original-Sender: cmbecker69@gmx.de X-Host-Fingerprint: 212.227.17.20 mout.gmx.net Received: from [212.227.17.20] ([212.227.17.20:61694] helo=mout.gmx.net) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 28/69-06271-E8E7E885 for ; Sun, 29 Jan 2017 18:45:18 -0500 Received: from [192.168.2.109] ([217.82.227.219]) by mail.gmx.com (mrgmx102 [212.227.17.168]) with ESMTPSA (Nemesis) id 0Lfppu-1c9JOV1bwY-00pPRu; Mon, 30 Jan 2017 00:45:13 +0100 To: Sammy Kaye Powers , PHP Internals References: Message-ID: Date: Mon, 30 Jan 2017 00:45:33 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Provags-ID: V03:K0:cIXilvgrS8nQaiDqKhjIcnrjONFeYJ1uZL0Eg3ECoYdCZdeQiQb RygNRjxqVLU7thIPOlNWtfgCJubAByIht0zV/QXLLfHM5+gQrZwJnm7DrIlSnIA6pvgRCls I8YFqbvoFeLKPrjo6awnIjJ7Geal2oAzd+pGwSWm+dfKIQU4Apc4phLmBqHaaGr0yGNw9ox J7379aS1VTQ95LxQSoslQ== X-UI-Out-Filterresults: notjunk:1;V01:K0:j/5UgwOPVUA=:Kywecb/H9I9hiicSi0SPAe 3N2a3rHC9Tv7hjBJjOicNxPpYRiaZXkdchrwjZvZg/lf98H4vhPyXG4ItQUX+2U2IKR+GiwjE zKgVBpkXvVxpMsICvBLX9Fej+TeRmbNZzVRYTzOaFqvLeHkJ/58r24dNJYA7fhVZTRjSicrJy 5p5hbxFLPN59OLPet6T7p2z4pdobNop0spCgI7yPM6BgNd8fZ87ET4jH1LON2lpFPUgl0q8ke JZ/N8NqC4Oc+r78jNYfJEBOB0N2lKT6ZJJzWeJbgXQ4eHKFAg6kj/llUNrabbri0X5j8w9DPp WinDmS3/YPiWq1Cbdl+o6HqfaGI3cJcblrJoP/hUnAPWLyC7rYpvgpQKzhczefgFNf8Z1vgEy iCR+U6/nwf1AvLNUfrizDzKYAaZ0dAn+A9XB0JuNkit0SCFl1HytocAgyLcQSRPjKsmW7mnYf iQt3A/GtyiWpVu+F3JoYXZtWLx6RnSH+qhCd5VMbAiw68FSrl0/7QnZNirO0FSB295/1d2XOf LntTaP3874Z8+7bQeQFVx7cefkfnOKrsh7VrkPJkDCKFJdikMR4pVNEWfen02tvnMjAsPl2Xq xdHH9jPmVmnK7YR4s5+CG58Y3XyQXrd2Xfx0GAUXbahQu/jGbhAXwJIfkWTZDPZE/o8CUnPxh ejrUvytZ+Z3uYr/9IBZgkJ7XhDS7/f9B34+fe7Ze+d8+x92IduQ2kS3HbzSxMy4WeOUyL8MU5 0+3EDyFNtG2j1nsMYgH281jVcIDWWb/vrWDwEMq1O4I4KS9ja0DA0kCHDHsjARhnE+9S9wCin 2PB85pe Subject: Re: [RFC][VOTE] Trailing commas in all list syntax From: cmbecker69@gmx.de ("Christoph M. Becker") On 27.01.2017 at 17:05, Sammy Kaye Powers wrote: > After a 2 week (ahem... 1 year & 3 month - sorry for dropping the > ball) discussion period, the "Trailing commas in all list syntax" RFC > is now open for voting. > > See the discussion here: > https://www.mail-archive.com/internals@lists.php.net/msg81366.html > > You can vote yay or nay for each possible list syntax individually. > > Voting will close 2017-02-10 16:00 (UTC). > > Thanks to @WesNetmo for pushing me to bring this to vote. The > community (or at least a sample from twitter) seems to want this > (https://twitter.com/sammyk/status/824298464456691712) so here we go! > :) Generally, I don't like these trailing commas, but indeed there is some value for lists that often have to be split across multiple lines. As such, my threshold is whether splitting certain lists across multiple lines is sensible. In my opinion, the following lists should usually be one-liners (because having too many items in the list would be a general design issue): * function/method *parameters* * interface implementations on a class * trait implementations on a class * class member list (I prefer a distinct statement for each member) * inheriting variables from the parent scope in anonymous functions An improvement might be allowing trailing commas in grouped namespaces, but I haven't enough experience with these to form an opinion. The only other case where allowing trailing commas would make sense, in my opinion, are function/methods *arguments* – there is, unfortunately for me, no explicit voting option. -- Christoph M. Becker