Re: Re: array_last_key() function

From: Date: Sat, 14 Jul 2012 00:32:13 +0000
Subject: Re: Re: array_last_key() function
References: 1 2  Groups: php.internals 
Request: Send a blank email to internals+get-61216@lists.php.net to get a copy of this message
I like this idea. array_first_key would be nice too On Fri, Jul 13, 2012 at 7:45 PM, Andrew Faulds <ajfweb@googlemail.com>wrote: > Changed, it now takes just an array. > > Function signature: > > mixed array_last_key(array $array) > > On 13 July 2012 23:31, Andrew Faulds <ajfweb@googlemail.com> 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/ > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > > -- *Brandon Wamboldt* Programmer / Web Developer StackOverflow Careers Profile<http://careers.stackoverflow.com/brandonwamboldt>- GitHub Profile <https://github.com/brandonwamboldt> - LinkedIn<https://github.com/brandonwamboldt> - My Blog <http://brandonwamboldt.ca/>

« previous php.internals (#61216) next »