Re: [PHP-DEV] SPL development interest

2020-05-25 Thread Benas IML
Hey, yes, there are no traits at the moment. Also, in PHP 8 there was `WeakMap` class added to the core as well. Best regards, Benas Seliuginas P.S: your email is marked as spam for me and probably for everyone else too, so most of the internals probably missed your emails. Try using a gmail-base

Re: [PHP-DEV] SPL development interest

2020-05-18 Thread Johannes Schlüter
On Sat, 2020-05-16 at 16:37 +0200, Jakob Givoni wrote: > The reason I was wondering about it was mostly for understanding > where > one would put Classes, Interfaces and Traits that should be essential > parts of the language. > F.ex. it seems the Countable interface should have been in the core >

Re: [PHP-DEV] SPL development interest

2020-05-18 Thread Levi Morrison via internals
In my opinion, another key takeaway: inheritance as a code reuse mechanism can really bite you. SplStack extends SplDoublyLinkedList and this exposes a bunch of methods on a stack that don't make any sense. It also means there are constraints on how well you can optimize the stack, because you have

Re: [PHP-DEV] SPL development interest

2020-05-18 Thread Johannes Schlüter
On Fri, 2020-05-15 at 12:53 +0100, Dan Ackroyd wrote: > Obviously, all of the following is my own personal opinion, and other > people may have different opinions. > > There are two main lessons learnt from the SPL experience. > > i) Some APIs need to evolve separately from the PHP release > sche

Re: [PHP-DEV] SPL development interest

2020-05-16 Thread Jakob Givoni
Thank you guys for your insights! You pretty much confirmed my fears about the SPL extension. The reason I was wondering about it was mostly for understanding where one would put Classes, Interfaces and Traits that should be essential parts of the language. F.ex. it seems the Countable interface

Re: [PHP-DEV] SPL development interest

2020-05-15 Thread Dan Ackroyd
On Thu, 14 May 2020 at 19:14, Jakob Givoni wrote: > > Hi Internals, > Hi Jakob, Obviously, all of the following is my own personal opinion, and other people may have different opinions. There are two main lessons learnt from the SPL experience. i) Some APIs need to evolve separately from the P