Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:84332 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 12878 invoked from network); 5 Mar 2015 10:30:59 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 5 Mar 2015 10:30:59 -0000 Authentication-Results: pb1.pair.com smtp.mail=j.boggiano@seld.be; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=j.boggiano@seld.be; sender-id=pass Received-SPF: pass (pb1.pair.com: domain seld.be designates 74.125.82.182 as permitted sender) X-PHP-List-Original-Sender: j.boggiano@seld.be X-Host-Fingerprint: 74.125.82.182 mail-we0-f182.google.com Received: from [74.125.82.182] ([74.125.82.182:39522] helo=mail-we0-f182.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 8A/D1-01843-16038F45 for ; Thu, 05 Mar 2015 05:30:59 -0500 Received: by wesu56 with SMTP id u56so8536800wes.6 for ; Thu, 05 Mar 2015 02:30:55 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:message-id:date:from:user-agent:mime-version:to :subject:references:in-reply-to:content-type :content-transfer-encoding; bh=EHmslpELsbo2phjbR50Iosz4OgUBRRowI21DRLw3Lik=; b=gGkaJA7H6ZSBbvHUPZ+mZm0KBS0zLwV900x1NLFrwguZqW5uEohHMPoNxoSviWrK00 yrQF3ePgCtf0FH6+4ow4BjGvO2wVC2UPiVXl01XHoKx8WPGhBkwPVs83KhBlR4AHH5JO 4j8O40+zUXPcITi0I3qv8daMEjJfKq2x+4K/zJFiN3lKPlSAbzKHPrUYhHS8NgYtGKJF 6NcSb5NsNk9Wbke/skmN/o+CUIOvtt9dsww3GAoDWvC8sNKEvv8l26rw+uDzQAkMe/Uh kNCDUbtoKL0V+QZeE1ljpQY09ykEFKc8tm+1bIMzxel4L9+cSN+6hQ8XhhS84oU9ZDyv a37w== X-Gm-Message-State: ALoCoQmbn8j1ALQm+7yzN6bF3NP02wL06qmcUceTQRKfU5OjWormBiUPF5RtdkTvEzfrNC0hhUrt X-Received: by 10.180.87.169 with SMTP id az9mr21264431wib.72.1425551455212; Thu, 05 Mar 2015 02:30:55 -0800 (PST) Received: from [192.168.1.74] ([87.113.223.175]) by mx.google.com with ESMTPSA id p1sm10988015wib.23.2015.03.05.02.30.53 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 05 Mar 2015 02:30:54 -0800 (PST) Message-ID: <54F83061.60108@seld.be> Date: Thu, 05 Mar 2015 10:30:57 +0000 User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.5.0 MIME-Version: 1.0 To: internals@lists.php.net References: In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] Re: [RFC] [DISCUSSION] Consistent Function Names From: j.boggiano@seld.be (Jordi Boggiano) On 05/03/2015 08:07, Yasuo Ohgaki wrote: > So array functions are subject to be changed. > > bool in_array ( mixed $needle , array $haystack [, bool $strict ] ) > Renamed to array_in() and fix order. > > mixed array_search ( mixed $needle , array $haystack [, bool $strict ] ) > Renamed to array_find() and fix order. > > bool array_key_exists ( mixed $key , array $array ) > Renamed to array_key_find() and fix order. > > array array_keys ( array $array [, mixed $search_value [, bool $strict = > false ]] ) > OK as it is now. > > implode() may be changed to have > string implode ( string $glue , array $pieces ) > always. If we do create new array functions I think it should be thought through a bit more than just cleaning up the arg order. For example we could support Traversable as well. Then at least it'd bring some value beyond consistency for the sake of it. Cheers