Newsgroups: php.internals,php.internals Path: news.php.net Xref: news.php.net php.internals:64939 php.internals:64940 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 22025 invoked from network); 14 Jan 2013 17:58:05 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 14 Jan 2013 17:58:05 -0000 X-Host-Fingerprint: 64.2.187.194 w194.z064002187.mco-fl.dsl.cnc.net Received: from [64.2.187.194] ([64.2.187.194:12796] helo=localhost.localdomain) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 01/65-22727-A2744F05 for ; Mon, 14 Jan 2013 12:58:02 -0500 To: internals@lists.php.net,Scott MacVicar Message-ID: <50F44726.3030706@php.net> Date: Mon, 14 Jan 2013 11:57:58 -0600 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:16.0) Gecko/20121026 Thunderbird/16.0.2 MIME-Version: 1.0 CC: internals@lists.php.net References: <42E4F513-0412-440D-BBBB-589F2A2463BD@macvicar.net> In-Reply-To: <42E4F513-0412-440D-BBBB-589F2A2463BD@macvicar.net> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Posted-By: 64.2.187.194 Subject: Re: [PHP-DEV] Re: [VOTE] array_column() function From: ramsey@php.net (Ben Ramsey) On 1/14/13 11:54 AM, Scott MacVicar wrote: > On 14 Jan 2013, at 11:37, Ben Ramsey wrote: > >> On 1/11/13 6:17 PM, Ben Ramsey wrote: >>> I've opened voting for the array_column() function RFC. >>> >>> You can vote at https://wiki.php.net/rfc/array_column#voting >> >> I have updated the pull request by removing the array_pluck() alias. I favor the array_column() alias, as it is more in keeping with other function names like array_keys() and array_values(), which do not have verbs in them. >> >> If the RFC is accepted, I will submit a new pull request against the 5.5 branch and close the current pull request against the 5.3 branch. If I should do that now, please let me know, and I'll go ahead and take care of it. > > I've talked about the Facebook version of this when the key bit got added, but we have 2 other methods to go with it. > > mpull() which does methods > https://github.com/facebook/libphutil/blob/master/src/utils/utils.php#L110 > > ppull() which does properties > https://github.com/facebook/libphutil/blob/master/src/utils/utils.php#L184 > > Not sure if these should be added separately? The property version is good for PDO when using FETCH_CLASS. > > - S > I did review these, and I like them, but I think they should be added separately, especially since they deal more with objects than arrays. -Ben