Find this useful? Enter your email to receive occasional updates for securing PHP code.

Signing you up...

Thank you for signing up!

PHP Decode

--TEST-- Bug GH-8063 (Opcache breaks autoloading after E_COMPILE_ERROR) 001 --INI-- opcach..

Decoded Output download

--TEST--
Bug GH-8063 (Opcache breaks autoloading after E_COMPILE_ERROR) 001
--INI--
opcache.enable=1
opcache.enable_cli=1
opcache.record_warnings=0
--EXTENSIONS--
opcache
--FILE--
<?php

spl_autoload_register(function ($class) {
    printf("Autoloading %s
", $class);
    include __DIR__.DIRECTORY_SEPARATOR.'gh8063'.DIRECTORY_SEPARATOR.$class.'.inc';
});

register_shutdown_function(function () {
    new Bar();
    new Baz();
    print "Finished
";
});

new BadClass();
--EXPECTF--
Autoloading BadClass
Autoloading Foo

Fatal error: Declaration of BadClass::dummy() must be compatible with Foo::dummy(): void in %sBadClass.inc on line 5
Autoloading Bar
Autoloading Baz
Finished
 ?>

Did this file decode correctly?

Original Code

--TEST--
Bug GH-8063 (Opcache breaks autoloading after E_COMPILE_ERROR) 001
--INI--
opcache.enable=1
opcache.enable_cli=1
opcache.record_warnings=0
--EXTENSIONS--
opcache
--FILE--
<?php

spl_autoload_register(function ($class) {
    printf("Autoloading %s\n", $class);
    include __DIR__.DIRECTORY_SEPARATOR.'gh8063'.DIRECTORY_SEPARATOR.$class.'.inc';
});

register_shutdown_function(function () {
    new Bar();
    new Baz();
    print "Finished\n";
});

new BadClass();
--EXPECTF--
Autoloading BadClass
Autoloading Foo

Fatal error: Declaration of BadClass::dummy() must be compatible with Foo::dummy(): void in %sBadClass.inc on line 5
Autoloading Bar
Autoloading Baz
Finished

Function Calls

None

Variables

None

Stats

MD5 fe4174b3245a31fc13f4c7d940ee24e2
Eval Count 0
Decode Time 91 ms