Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:96678 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 33960 invoked from network); 31 Oct 2016 17:27:17 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 31 Oct 2016 17:27:17 -0000 Authentication-Results: pb1.pair.com smtp.mail=larry@garfieldtech.com; spf=permerror; sender-id=unknown Authentication-Results: pb1.pair.com header.from=larry@garfieldtech.com; sender-id=unknown Received-SPF: error (pb1.pair.com: domain garfieldtech.com from 66.111.4.26 cause and error) X-PHP-List-Original-Sender: larry@garfieldtech.com X-Host-Fingerprint: 66.111.4.26 out2-smtp.messagingengine.com Received: from [66.111.4.26] ([66.111.4.26:58964] helo=out2-smtp.messagingengine.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 39/B0-25911-4FE77185 for ; Mon, 31 Oct 2016 12:27:16 -0500 Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.nyi.internal (Postfix) with ESMTP id B24B520791 for ; Mon, 31 Oct 2016 13:27:13 -0400 (EDT) Received: from frontend1 ([10.202.2.160]) by compute3.internal (MEProxy); Mon, 31 Oct 2016 13:27:13 -0400 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc:x-sasl-enc; s= smtpout; bh=gDkIVr7rscSDuJUTdWX5Ir+KfwY=; b=BIloNfEUubFWJzZA8sGc wtaLVJ5UfnhzNkcB9ZUwR/nwN23reiGYHYEwsaugG7wgvxXhv4ablCQM7GPa0ygj Np7sjEYsR0k3zXv52jeEuKYgGJcvk0h1sqhXGfe7Xv2eX+6nPsp+tVoLbsbgTIwg RbBX/KifG1hDCDLyytd2Vfg= X-ME-Sender: X-Sasl-enc: zFOsEIPurRoFE2ebf0zxUnhF2jck/zBCW8BrFwr+b4OL 1477934833 Received: from [192.168.42.5] (c-50-178-40-84.hsd1.il.comcast.net [50.178.40.84]) by mail.messagingengine.com (Postfix) with ESMTPA id 7C2B9F29D0 for ; Mon, 31 Oct 2016 13:27:13 -0400 (EDT) To: internals@lists.php.net References: <44244cfd-c8ad-e0a9-4e70-380a8a8c940c@syberisle.net> <01f2f3da-592b-fd23-709d-ad620422f56d@fleshgrinder.com> <7fb9a5d5-318d-7ed3-59eb-d9845ed5dec1@gmail.com> Message-ID: <5219c048-66f1-be9a-ae3c-15633a65e263@garfieldtech.com> Date: Mon, 31 Oct 2016 12:27:13 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.3.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] Allow Iterator to be used with current, next, reset, key functions From: larry@garfieldtech.com (Larry Garfield) On 10/31/2016 11:26 AM, Alice Wonder wrote: > On 10/30/2016 10:19 AM, Rowan Collins wrote: > >> >> - deprecate reset(), end(), each(), and key() >> - introduce array_first(), array_last(), array_first_key() and >> array_last_key() >> - document replacements for whatever other use cases we can find >> examples of >> > > As a user I certainly like those names better. Semantic function names > are a definite win in my view. Question: Now that we have "iterable" as a type, should we be adding more array-specific functions or should such operations be designed, and named, to operate on any iterable? (first(), first_key(), etc.) --Larry Garfield