php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #78950 Assertion failure when preloading trait method with static variables
Submitted: 2019-12-12 09:34 UTC Modified: -
From: nikic@php.net Assigned:
Status: Closed Package: opcache
PHP Version: 7.4.0 OS:
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: nikic@php.net
New email:
PHP Version: OS:

 

 [2019-12-12 09:34 UTC] nikic@php.net
Description:
------------
<?php
trait Foo {
    public function test() {
        static $bar;
    }
}
class Bar {
    use Foo;
}

Causes:

php: /home/nikic/php-7.4/ext/opcache/zend_persist.c:300: zend_persist_op_array_ex: Assertion `op_array->static_variables != ((void *)0)' failed.



Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2019-12-12 10:52 UTC] nikic@php.net
Automatic comment on behalf of nikita.ppv@gmail.com
Revision: http://git.php.net/?p=php-src.git;a=commit;h=be89a5c7f191b319c11b3b487a1366e20a1fdc17
Log: Fixed bug #78950: Preloading trait method with static variables
 [2019-12-12 10:52 UTC] nikic@php.net
-Status: Open +Status: Closed
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Dec 03 16:01:33 2024 UTC