Re: [PHP-DEV] array_seek function

2010-04-13 Thread Felix De Vliegher
On 12-apr-2010, at 10:20, Derick Rethans wrote: On Mon, 22 Mar 2010, Felix De Vliegher wrote: On 17-mrt-2010, at 19:09, Derick Rethans wrote: On Wed, 17 Mar 2010, Felix De Vliegher wrote: On 17-mrt-2010, at 17:52, Derick Rethans wrote: On Wed, 17 Mar 2010, Felix De Vliegher wrote

[PHP-DEV] Open PHP6/trunk bugs

2010-03-24 Thread Felix De Vliegher
Hi Ulf already indicated this in a bug report, but I'd like to bring it up here too: There's no PHP 6 any more. What shall happen to those reports: close, bogus, test against 5.3, test against new trunk? There's a lot of open PHP6 / SVN snaps bugs, some of them obviously not valid anymore

Re: [PHP-DEV] array_seek function

2010-03-22 Thread Felix De Vliegher
On 17-mrt-2010, at 19:09, Derick Rethans wrote: On Wed, 17 Mar 2010, Felix De Vliegher wrote: On 17-mrt-2010, at 17:52, Derick Rethans wrote: On Wed, 17 Mar 2010, Felix De Vliegher wrote: On 17-mrt-2010, at 17:27, Frederic Hardy wrote: Why not use arrayIterator::seek() ? Because

Re: [PHP-DEV] array_seek function

2010-03-17 Thread Felix De Vliegher
On 17-mrt-2010, at 17:00, Patrick ALLAERT wrote: 2010/3/16 Felix De Vliegher felix.devlieg...@gmail.com: Hi all I recently needed seek functionality in arrays, and couldn't find it in the regular set of array functions, so I wrote a function for it. (Seek = getting an array value based

Re: [PHP-DEV] array_seek function

2010-03-17 Thread Felix De Vliegher
On 17-mrt-2010, at 17:27, Frederic Hardy wrote: Hello Felix ! Why not use arrayIterator::seek() ? Best regards, Fred Because the functionality isn't exactly the same. ArrayIterator::seek() only sets the array pointer, array_seek would also return the value + have fseek()-like

Re: [PHP-DEV] array_seek function

2010-03-17 Thread Felix De Vliegher
On 17-mrt-2010, at 17:52, Derick Rethans wrote: On Wed, 17 Mar 2010, Felix De Vliegher wrote: On 17-mrt-2010, at 17:27, Frederic Hardy wrote: Why not use arrayIterator::seek() ? Because the functionality isn't exactly the same. ArrayIterator::seek() only sets the array pointer

Re: [PHP-DEV] array_seek function

2010-03-17 Thread Felix De Vliegher
On 17-mrt-2010, at 19:09, Derick Rethans wrote: On Wed, 17 Mar 2010, Felix De Vliegher wrote: On 17-mrt-2010, at 17:52, Derick Rethans wrote: On Wed, 17 Mar 2010, Felix De Vliegher wrote: On 17-mrt-2010, at 17:27, Frederic Hardy wrote: Why not use arrayIterator::seek() ? Because

[PHP-DEV] array_seek function

2010-03-16 Thread Felix De Vliegher
Hi all I recently needed seek functionality in arrays, and couldn't find it in the regular set of array functions, so I wrote a function for it. (Seek = getting an array value based on the position (or offset, if you want to call it like that), and not the key of the item) Basically you can

Re: [PHP-DEV] array_seek function

2010-03-16 Thread Felix De Vliegher
is misleading (pls reattach the patch as .txt while being at it :). Does it set the position (_seek) or does it return the value of a given position (_get_pos)? or both (no idea :)? Cheers, Cheers, On Tue, Mar 16, 2010 at 2:30 PM, Felix De Vliegher felix.devlieg...@gmail.com wrote: Hi

Re: [PHP-DEV] array_seek function

2010-03-16 Thread Felix De Vliegher
On 16-mrt-2010, at 17:07, Derick Rethans wrote: On Tue, 16 Mar 2010, Felix De Vliegher wrote: Right now, it returns the value of a given position. In that case, array_get_pos might be a better name. Oh, and I attached the patch with .txt extension :) Does it also seek the array pointer

Re: [PHP-DEV] array_seek function

2010-03-16 Thread Felix De Vliegher
Hi As SEEK_END only makes sense with zero or negative offsets (for arrays anyway), I've come up with an implementation for SEEK_END: http://phpbenelux.eu/array_seek.patch.txt So you can do: $arr = array('a', 'b', 'c', 'd'); echo array_seek($arr, -2, SEEK_END); // outputs 'b' echo

Re: [PHP-DEV] keeping traffic on this list manageable

2008-10-31 Thread Felix De Vliegher
Hi Lukas Sounds like a good idea to channel the volume on this list. I was wondering, would the usergroup part be a replacement for the moderated messages by regular users or would it be an addition to it? I mean, we should better start promoting this one moderator-per- usergroup to

[PHP-DEV] CVS Account Request: felixdv

2008-06-16 Thread Felix De Vliegher
Writing PHPT tests (I already wrote about 35 tests, which can be found on http://testfest.php.net). pierre, zoe and lsmith should be able to confirm my cvs account request. -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php