Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:61213 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 8585 invoked from network); 13 Jul 2012 22:46:09 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 13 Jul 2012 22:46:09 -0000 Authentication-Results: pb1.pair.com header.from=ajfweb@googlemail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=ajfweb@googlemail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain googlemail.com designates 74.125.82.170 as permitted sender) X-PHP-List-Original-Sender: ajfweb@googlemail.com X-Host-Fingerprint: 74.125.82.170 mail-we0-f170.google.com Received: from [74.125.82.170] ([74.125.82.170:55884] helo=mail-we0-f170.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id EF/02-20866-035A0005 for ; Fri, 13 Jul 2012 18:46:09 -0400 Received: by weyr1 with SMTP id r1so3016688wey.29 for ; Fri, 13 Jul 2012 15:46:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type; bh=ln62o20j7owHSnyAjAmqpeYhMS39asFboYeiSkcxVNM=; b=MX0ZM0R150zu1G4P0YCP6cnAFx0glSphG5zTjUSEYgF++ohWFAOMSvVmGHKPfqemJn w9OFJQFo0yy8jznTndeE+fhfz7uqJuNz5OfI55xzezcMYFEjaFSjvIdVq8fqZqrKImfI VIddv/vnE9e7xyG7P3nPyLZlUGNzZ5cxGFFGAl/GwZ/eYX9PXVsfMyvpx/F3S1PoUFZ4 hZ++YhYvVarjYcId+6LAk0rEGN4M4aqiVFgulK55JbZGLwl8fq+lOGo1whod5SHNY4Dm eBfgZPRm4Y+b0zgDuJc6IZcr1195M05QKocdiu1/iTEy1TtWbJ8AEQoiwi0CN8/zbLgt o8Sw== Received: by 10.180.76.135 with SMTP id k7mr1073650wiw.7.1342219565127; Fri, 13 Jul 2012 15:46:05 -0700 (PDT) MIME-Version: 1.0 Received: by 10.216.71.199 with HTTP; Fri, 13 Jul 2012 15:45:44 -0700 (PDT) In-Reply-To: References: Date: Fri, 13 Jul 2012 23:45:44 +0100 Message-ID: To: internals Content-Type: text/plain; charset=UTF-8 Subject: Re: array_last_key() function From: ajfweb@googlemail.com (Andrew Faulds) Changed, it now takes just an array. Function signature: mixed array_last_key(array $array) On 13 July 2012 23:31, Andrew Faulds wrote: > Hi there, > > I'm proposing a function called array_last_key(), that takes a > reference to an array, and returns the key of its last item. This is > useful for finding out the key of the last item pushed to an array. > Here's the pull request: https://github.com/php/php-src/pull/131 > > This is the first PHP extension function, and PHP test I've written. > > -- > Andrew Faulds (AJF) > http://ajf.me/ -- Andrew Faulds (AJF) http://ajf.me/