Only lazy developers would complain about updating legacy code, perhaps the code itself is worthless and need not be updated.
Then, what's the point of pursuing latest features or PHP version when a individual or a company can't pursue code upgrade before version update? On Tue, Jan 21, 2020, 8:41 PM Philip Hofstetter <phofstet...@sensational.ch> wrote: > Hi, > > > On Tue, Jan 21, 2020 at 6:17 PM Nikita Popov <nikita....@gmail.com> wrote: > > > > > In the cases you encountered, do you know what type count() was used on? > > Was it null? false? Or something else? > > > > Nikita > > we were in a similar boat as Björn to the point where we manually > patched PHP in production in order to not emit that warning so we > could update PHP while we were migrating the code-base. This made the > 7.1 to 7.2 update the most painful update in the history of this > application (which was first released when 5.0.0 came out). > > The most common case was `count(null)` which unfortunately was > happening all the time because of functions deciding to return an > array with elements or null if there was no elements to be found. Yes, > that's bad form, but hey - this is a nearly 20 years old application. > > Of all the changes I've seen happening in PHP, this was the most painful. > > Philip > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > >