]> granicus.if.org Git - php/commit
Fix $x = (bool)$x; for undefined with opcache
authorTyson Andre <tysonandre775@hotmail.com>
Fri, 15 Nov 2019 17:47:32 +0000 (12:47 -0500)
committerDmitry Stogov <dmitry@zend.com>
Mon, 18 Nov 2019 08:24:03 +0000 (11:24 +0300)
commita2c41c0ea6e6b6afbfaaeae25e66fd17e746a98a
tree3d599b8e163bc0596555a4a7b6b8ffbc5126b234
parent2c9926f156b2be6aa4f69a169d028c1ebc1eaa34
Fix $x = (bool)$x; for undefined with opcache

And `$x = !$x`

Noticed while working on GH-4912

The included test would not emit undefined variable errors in php 8.0
with opcache enabled. The command used:

```
php -d zend_extension=opcache.so --no-php-ini -d error_reporting=E_ALL \
    -d opcache.file_cache= -d opcache.enable_cli=1  test.php
```
Zend/zend_vm_def.h
Zend/zend_vm_execute.h
ext/opcache/tests/bool_not_cv.phpt [new file with mode: 0644]