3v4l.org

run code in 300+ PHP versions simultaneously
<?php class A { private function __construct() { throw new Exception('thrown'); } public function A() { return array('a', 'b', 'c'); } public static function I() { return new A(); } } $A = 'A'; call_user_method(array($A, 'A'), null);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/J5jqM
function name:  (null)
number of ops:  8
compiled vars:  !0 = $A
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   20     0  E >   ASSIGN                                                   !0, 'A'
   21     1        INIT_FCALL_BY_NAME                                       'call_user_method'
          2        INIT_ARRAY                                       ~2      !0
          3        ADD_ARRAY_ELEMENT                                ~2      'A'
          4        SEND_VAL_EX                                              ~2
          5        SEND_VAL_EX                                              null
          6        DO_FCALL                                      0          
          7      > RETURN                                                   1

Class A:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 108) Position 1 = -2
filename:       /in/J5jqM
function name:  __construct
number of ops:  5
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   NEW                                              $0      'Exception'
          1        SEND_VAL_EX                                              'thrown'
          2        DO_FCALL                                      0          
          3      > THROW                                         0          $0
    8     4*     > RETURN                                                   null

End of function __construct

Function a:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/J5jqM
function name:  A
number of ops:  2
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E > > RETURN                                                   <array>
   13     1*     > RETURN                                                   null

End of function a

Function i:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/J5jqM
function name:  I
number of ops:  4
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   17     0  E >   NEW                                              $0      'A'
          1        DO_FCALL                                      0          
          2      > RETURN                                                   $0
   18     3*     > RETURN                                                   null

End of function i

End of class A.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
160.71 ms | 1395 KiB | 13 Q