3v4l.org

run code in 300+ PHP versions simultaneously
<?php class a { function __construct() { echo 'hi'; } } //$obj = new ReflectionFunction('phpinfo'); //var_dump(serialize($obj)); $str = 'O:18:"ReflectionFunction":1:{s:4:"info";a:14:{s:4:"name";s:7:"phpinfo";s:7:"closure";s:0:"";s:8:"internal";b:1;s:11:"return_type";b:0;s:3:"doc";b:0;s:6:"params";a:1:{i:0;a:9:{s:5:"index";i:0;s:4:"name";s:4:"what";s:4:"type";s:0:"";s:9:"type_hint";s:0:"";s:8:"function";s:7:"phpinfo";s:8:"nullable";b:1;s:7:"default";i:0;s:11:"defaultText";s:1:"0";s:10:"attributes";a:0:{}}}s:16:"static_variables";a:0:{}s:10:"attributes";a:0:{}s:8:"is_async";b:0;s:10:"is_closure";b:0;s:12:"is_generator";b:0;s:4:"file";s:2:"//";s:5:"line1";i:0;s:5:"line2";i:0;}}'; var_dump(unserialize($str));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/BKmES
function name:  (null)
number of ops:  8
compiled vars:  !0 = $str
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   ASSIGN                                                   !0, 'O%3A18%3A%22ReflectionFunction%22%3A1%3A%7Bs%3A4%3A%22info%22%3Ba%3A14%3A%7Bs%3A4%3A%22name%22%3Bs%3A7%3A%22phpinfo%22%3Bs%3A7%3A%22closure%22%3Bs%3A0%3A%22%22%3Bs%3A8%3A%22internal%22%3Bb%3A1%3Bs%3A11%3A%22return_type%22%3Bb%3A0%3Bs%3A3%3A%22doc%22%3Bb%3A0%3Bs%3A6%3A%22params%22%3Ba%3A1%3A%7Bi%3A0%3Ba%3A9%3A%7Bs%3A5%3A%22index%22%3Bi%3A0%3Bs%3A4%3A%22name%22%3Bs%3A4%3A%22what%22%3Bs%3A4%3A%22type%22%3Bs%3A0%3A%22%22%3Bs%3A9%3A%22type_hint%22%3Bs%3A0%3A%22%22%3Bs%3A8%3A%22function%22%3Bs%3A7%3A%22phpinfo%22%3Bs%3A8%3A%22nullable%22%3Bb%3A1%3Bs%3A7%3A%22default%22%3Bi%3A0%3Bs%3A11%3A%22defaultText%22%3Bs%3A1%3A%220%22%3Bs%3A10%3A%22attributes%22%3Ba%3A0%3A%7B%7D%7D%7Ds%3A16%3A%22static_variables%22%3Ba%3A0%3A%7B%7Ds%3A10%3A%22attributes%22%3Ba%3A0%3A%7B%7Ds%3A8%3A%22is_async%22%3Bb%3A0%3Bs%3A10%3A%22is_closure%22%3Bb%3A0%3Bs%3A12%3A%22is_generator%22%3Bb%3A0%3Bs%3A4%3A%22file%22%3Bs%3A2%3A%22%2F%2F%22%3Bs%3A5%3A%22line1%22%3Bi%3A0%3Bs%3A5%3A%22line2%22%3Bi%3A0%3B%7D%7D'
   12     1        INIT_FCALL                                               'var_dump'
          2        INIT_FCALL                                               'unserialize'
          3        SEND_VAR                                                 !0
          4        DO_ICALL                                         $2      
          5        SEND_VAR                                                 $2
          6        DO_ICALL                                                 
          7      > RETURN                                                   1

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

End of function __construct

End of class a.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
177.91 ms | 1395 KiB | 17 Q