Re: [PHP-DEV] [RFC] Static variables in inherited methods

2021-02-25 Thread Glash Gnome
I can understand that some people coming from C++, Java may be shocked by the behavior of a static variable in a static function. And the need to improve things. Maybe can you add *virtual static* keywords as a replacement for old behavior in your RFC

Re: [PHP-DEV] [RFC] Static variables in inherited methods

2021-02-25 Thread Nikita Popov
On Thu, Feb 25, 2021 at 4:46 PM Glash Gnome wrote: > Dears, > > Let me briefly introduce myself. I have been a C coder for 19 years, > including 12 years with php. And I also do Java, C++, Javascript... from > time to time. > > Nikita, What would the equivalent of this code be after RFC modificat

Re: [PHP-DEV] [RFC] Static variables in inherited methods

2021-02-25 Thread Glash Gnome
Dears, Let me briefly introduce myself. I have been a C coder for 19 years, including 12 years with php. And I also do Java, C++, Javascript... from time to time. Nikita, What would the equivalent of this code be after RFC modification? a écrit : > Hi internals, > > While looking into various

Re: [PHP-DEV] [RFC] Static variables in inherited methods

2021-02-25 Thread Nikita Popov
On Thu, Feb 25, 2021 at 9:48 AM Aleksander Machniak wrote: > On 23.02.2021 15:01, Nikita Popov wrote: > > While looking into various issues related to static variable handling, > I've > > become increasingly convinced that our handling of static variables in > > inherited methods is outright bugg

Re: [PHP-DEV] [RFC] Static variables in inherited methods

2021-02-25 Thread Aleksander Machniak
On 23.02.2021 15:01, Nikita Popov wrote: > While looking into various issues related to static variable handling, I've > become increasingly convinced that our handling of static variables in > inherited methods is outright buggy. However, it's also long-standing > behavior, so I've put up an RFC:

Re: [PHP-DEV] [RFC] Static variables in inherited methods

2021-02-25 Thread Dmitry Stogov
+1 On Tue, Feb 23, 2021 at 5:02 PM Nikita Popov wrote: > Hi internals, > > While looking into various issues related to static variable handling, I've > become increasingly convinced that our handling of static variables in > inherited methods is outright buggy. However, it's also long-standing

[PHP-DEV] [RFC] Static variables in inherited methods

2021-02-23 Thread Nikita Popov
Hi internals, While looking into various issues related to static variable handling, I've become increasingly convinced that our handling of static variables in inherited methods is outright buggy. However, it's also long-standing behavior, so I've put up an RFC: https://wiki.php.net/rfc/static_v