3v4l.org

run code in 300+ PHP versions simultaneously
<?php class logger { function __construct() { print "logger constructing\n"; } function __wakeup() { print "logger wakeup\n"; } function __destruct() { print "logger destruct\n"; } } class obj { var $prop; function __wakeup() { $this->prop = 'awake'; } } $x = 'a:4:{i:0;O:8:"stdClass":1:{i:0;O:6:"logger":0:{};}i:1;O:3:"obj":1:{s:4:"prop";R:2;}i:2;R:3}'; $y = unserialize($x); var_dump($y);
Output for git.master, git.master_jit
Notice: unserialize(): Error at offset 48 of 91 bytes in /in/49ZaI on line 22 logger wakeup logger destruct bool(false)
Output for rfc.property-hooks
Warning: unserialize(): Error at offset 48 of 91 bytes in /in/49ZaI on line 22 logger wakeup logger destruct bool(false)

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:
51.08 ms | 401 KiB | 8 Q