I have just noticed that the current SPL inplementation of a
DoublyLinkedList does not include methods to insert nodes into the middle
of the list (insertBefore, insertAfter).
After mentioning it I ran into a few people and other outbursts on the
internet of more people who saw this and complained about it.
I found a bug from 2009 (https://bugs.php.net/bug.php?id=48358) which
mentions the case and has no Core response at all.
I ask two questions:
-
Why was this bug never replied to, is there some reason these methods
should not be implemented? -
Is anyone willing to put up a patch for this? I imagine that if you are
familiar with C and PHP source this is a quick implementation as its
standard logic documented everywhere.
I'm not familiar enough with the PHP source to do this myself, hence I'm
asking for anyone willing to "champion" the patch.
Thanks!
--
Rafael Dohms
PHP Evangelist and Community Leader
http://www.rafaeldohms.com.br
http://www.amsterdamphp.nl
Hi Rafael,
I have worked on this code before and if the idea is accepted I'm happy to
add features to this class.
Let me know.
Thanks,
Paul.
On Thu, Nov 29, 2012 at 11:38 AM, Rafael Dohms listas@rafaeldohms.com.brwrote:
I have just noticed that the current SPL inplementation of a
DoublyLinkedList does not include methods to insert nodes into the middle
of the list (insertBefore, insertAfter).After mentioning it I ran into a few people and other outbursts on the
internet of more people who saw this and complained about it.I found a bug from 2009 (https://bugs.php.net/bug.php?id=48358) which
mentions the case and has no Core response at all.I ask two questions:
Why was this bug never replied to, is there some reason these methods
should not be implemented?Is anyone willing to put up a patch for this? I imagine that if you are
familiar with C and PHP source this is a quick implementation as its
standard logic documented everywhere.I'm not familiar enough with the PHP source to do this myself, hence I'm
asking for anyone willing to "champion" the patch.Thanks!
--
Rafael Dohms
PHP Evangelist and Community Leader
http://www.rafaeldohms.com.br
http://www.amsterdamphp.nl
I have just noticed that the current SPL inplementation of a
DoublyLinkedList does not include methods to insert nodes into the middle
of the list (insertBefore, insertAfter).After mentioning it I ran into a few people and other outbursts on the
internet of more people who saw this and complained about it.I found a bug from 2009 (https://bugs.php.net/bug.php?id=48358) which
mentions the case and has no Core response at all.I ask two questions:
Why was this bug never replied to, is there some reason these methods
should not be implemented?Is anyone willing to put up a patch for this? I imagine that if you are
familiar with C and PHP source this is a quick implementation as its
standard logic documented everywhere.
I am creating a library in PHP code that includes a linked list with
this feature (https://github.com/morrisonlevi/PHP-Datastructures/blob/master/src/Spl/LinkedList.php).
I'd love for you to use it while you wait for the core to be patched
and give me some feedback.
It would be an awesome feature, indeed.
Daniel Ribeiro Gomes Pereira
Twitter https://twitter.com/#!/drgomesp |
Facebookhttps://www.facebook.com/profile.php?id=100000407054469
| LinkedIn http://www.linkedin.com/pub/daniel-ribeiro-gomes/21/414/39
iPhone: +55 (48) 9111-0931
2012/11/29 Levi Morrison morrison.levi@gmail.com
On Thu, Nov 29, 2012 at 4:38 AM, Rafael Dohms listas@rafaeldohms.com.br
wrote:I have just noticed that the current SPL inplementation of a
DoublyLinkedList does not include methods to insert nodes into the middle
of the list (insertBefore, insertAfter).After mentioning it I ran into a few people and other outbursts on the
internet of more people who saw this and complained about it.I found a bug from 2009 (https://bugs.php.net/bug.php?id=48358) which
mentions the case and has no Core response at all.I ask two questions:
Why was this bug never replied to, is there some reason these methods
should not be implemented?Is anyone willing to put up a patch for this? I imagine that if you
are
familiar with C and PHP source this is a quick implementation as its
standard logic documented everywhere.I am creating a library in PHP code that includes a linked list with
this feature (
https://github.com/morrisonlevi/PHP-Datastructures/blob/master/src/Spl/LinkedList.php
).
I'd love for you to use it while you wait for the core to be patched
and give me some feedback.