3v4l.org

run code in 500+ PHP versions simultaneously
<?php class Foo { public $prop; } Class Bar { public int $a; // <== Bar::$a MUST be an integer but ... public function __destruct() { var_dump($this->a); } } unserialize('O:3:"Bar":1:{s:1:"a";O:3:"Foo":2:{s:4:"prop";s:3:"baz";}}');
Output for master
Warning: unserialize(): Unexpected end of serialized data in /in/7deSd on line 16 Warning: unserialize(): Error at offset 55 of 57 bytes in /in/7deSd on line 16 Fatal error: Uncaught Error: Typed property Bar::$a must not be accessed before initialization in /in/7deSd:12 Stack trace: #0 [internal function]: Bar->__destruct() #1 /in/7deSd(16): unserialize('O:3:"Bar":1:{s:...') #2 {main} thrown in /in/7deSd on line 12
Process exited with code 255.

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
12.73 ms | 1195 KiB | 7 Q