Subscribe to PHP Freaks RSS

PHP 8.0 feature focus: <span>Language tightenings</span>

syndicated from planet-php.net on October 21, 2020

In our last chapter we went over several smaller feature improvements to PHP. Today, we’ll cover several minor language changes that make PHP safer, but may trip up some older code. There’s been a very steady trend in PHP over the last several years toward making the language tighter. That means more edge cases that are “undefined behavior that kinda silently works most of the time” turn into explicit warnings or errors, behavior that was documented but totally illogical gets adjusted to be more logical, and so on.