3v4l.org

run code in 300+ PHP versions simultaneously
<?php class A { var $one = "111"; function __construct() { echo "construct";} function __destruct() { echo "destruct".$this->one;} //function __wakeup() { echo "wakeup";} } //$at = new A(); $x = 'C:1:"A":31:{s:5:"one()";s:11:"__construct";}'; echo $x; $u = unserialize($x); var_dump($u); ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Q7TPr
function name:  (null)
number of ops:  10
compiled vars:  !0 = $x, !1 = $u
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   ASSIGN                                                   !0, 'C%3A1%3A%22A%22%3A31%3A%7Bs%3A5%3A%22one%28%29%22%3Bs%3A11%3A%22__construct%22%3B%7D'
    9     1        ECHO                                                     !0
   10     2        INIT_FCALL                                               'unserialize'
          3        SEND_VAR                                                 !0
          4        DO_ICALL                                         $3      
          5        ASSIGN                                                   !1, $3
   11     6        INIT_FCALL                                               'var_dump'
          7        SEND_VAR                                                 !1
          8        DO_ICALL                                                 
   13     9      > RETURN                                                   1

Class A:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Q7TPr
function name:  __construct
number of ops:  2
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ECHO                                                     'construct'
          1      > RETURN                                                   null

End of function __construct

Function __destruct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Q7TPr
function name:  __destruct
number of ops:  4
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   FETCH_OBJ_R                                      ~0      'one'
          1        CONCAT                                           ~1      'destruct', ~0
          2        ECHO                                                     ~1
          3      > RETURN                                                   null

End of function __destruct

End of class A.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
163.98 ms | 940 KiB | 18 Q