3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php class hi { function __destruct() { echo 'hi'; } } $foo = 'O:2:"hi":0:'; $data = unserialize($foo); var_dump($data);
Finding entry points
Branch analysis from position: 0
Jump found. (Code = 62) Position 1 = -2
filename:       /in/amB0d
function name:  (null)
number of ops:  10
compiled vars:  !0 = $foo, !1 = $data
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   3     0  E >   NOP                                                      
   8     1        ASSIGN                                                   !0, 'O%3A2%3A%22hi%22%3A0%3A'
   9     2        INIT_FCALL                                               'unserialize'
         3        SEND_VAR                                                 !0
         4        DO_ICALL                                         $4      
         5        ASSIGN                                                   !1, $4
  10     6        INIT_FCALL                                               'var_dump'
         7        SEND_VAR                                                 !1
         8        DO_ICALL                                                 
         9      > RETURN                                                   1

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

End of function __destruct

End of class hi.

Generated using Vulcan Logic Dumper, using php 7.1.0