[php-src] PR #16639: Fix assertion failure in zend_std_read_property

From: Date: Tue, 29 Oct 2024 12:27:24 +0000
Subject: [php-src] PR #16639: Fix assertion failure in zend_std_read_property
Groups: php.git-pulls 
Request: Send a blank email to git-pulls+get-29437@lists.php.net to get a copy of this message
Pull Request: https://github.com/php/php-src/pull/16639 Author: arnaud-lb Fixes GH-16615. We assert that Z_PROP_FLAG_P(retval) is exactly IS_PROP_UNINIT, but this is a bit field and it may contain irrelevant bits. For instance, props may also have the IS_PROP_LAZY or IS_PROP_REINITABLE bits, which does not change the fact that the property is uninitialized: ``` php <?php class Foo { public string $bar { set => $value; } public function __clone() { // Assertion failure echo $this->bar; } } clone new Foo(); ``` @nielsdos I didn't update the comment because it's still correct, and I think that using equality comparison was unintended.

« previous php.git-pulls (#29437) next »