3v4l.org

run code in 300+ PHP versions simultaneously
<?php $obj = (object) array( "\0*\0bar" => 1, "\0Foo\0baz" => 2, ); class Foo { public function getVars($obj) { var_dump(get_object_vars($obj)); } } var_dump(get_object_vars($obj)); (new Foo())->getVars($obj);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/DWGHj
function name:  (null)
number of ops:  14
compiled vars:  !0 = $obj
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   CAST                                          8  ~1      <array>
    3     1        ASSIGN                                                   !0, ~1
   16     2        INIT_FCALL                                               'var_dump'
          3        INIT_FCALL                                               'get_object_vars'
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                         $3      
          6        SEND_VAR                                                 $3
          7        DO_ICALL                                                 
   17     8        NEW                                              $5      'Foo'
          9        DO_FCALL                                      0          
         10        INIT_METHOD_CALL                                         $5, 'getVars'
         11        SEND_VAR_EX                                              !0
         12        DO_FCALL                                      0          
         13      > RETURN                                                   1

Class Foo:
Function getvars:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/DWGHj
function name:  getVars
number of ops:  8
compiled vars:  !0 = $obj
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   RECV                                             !0      
   12     1        INIT_FCALL                                               'var_dump'
          2        INIT_FCALL                                               'get_object_vars'
          3        SEND_VAR                                                 !0
          4        DO_ICALL                                         $1      
          5        SEND_VAR                                                 $1
          6        DO_ICALL                                                 
   13     7      > RETURN                                                   null

End of function getvars

End of class Foo.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
165.36 ms | 1395 KiB | 17 Q