3v4l.org

run code in 500+ PHP versions simultaneously
<?php abstract class Super { public function __construct($something) { $this->something = $something; } public static function make($array) { return array_map(function ($el) { return new static($el); }, $array); } } class Child extends Super { } echo phpversion(), "\n"; print_r(Child::make([1,2,3]));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/lk4i0
function name:  (null)
number of ops:  11
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   21     0  E >   INIT_FCALL                                                   'phpversion'
          1        DO_ICALL                                             $0      
          2        ECHO                                                         $0
          3        ECHO                                                         '%0A'
   22     4        INIT_FCALL                                                   'print_r'
          5        INIT_STATIC_METHOD_CALL                                      'Child', 'make'
          6        SEND_VAL                                                     <array>
          7        DO_FCALL                                          0  $1      
          8        SEND_VAR                                                     $1
          9        DO_ICALL                                                     
         10      > RETURN                                                       1

Class Super:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/lk4i0
function name:  __construct
number of ops:  4
compiled vars:  !0 = $something
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    4     0  E >   RECV                                                 !0      
    6     1        ASSIGN_OBJ                                                   'something'
          2        OP_DATA                                                      !0
    7     3      > RETURN                                                       null

End of function __construct

Function make:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/lk4i0
function name:  make
number of ops:  8
compiled vars:  !0 = $array
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    9     0  E >   RECV                                                 !0      
   11     1        INIT_FCALL                                                   'array_map'
          2        DECLARE_LAMBDA_FUNCTION                              ~1      [0]
   13     3        SEND_VAL                                                     ~1
          4        SEND_VAR                                                     !0
   11     5        DO_ICALL                                             $2      
   13     6      > RETURN                                                       $2
   14     7*     > RETURN                                                       null


Dynamic Functions:
Dynamic Function 0
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/lk4i0
function name:  {closure:Super::make():11}
number of ops:  6
compiled vars:  !0 = $el
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   11     0  E >   RECV                                                 !0      
   12     1        NEW                              static              $1      
          2        SEND_VAR_EX                                                  !0
          3        DO_FCALL                                          0          
          4      > RETURN                                                       $1
   13     5*     > RETURN                                                       null

End of Dynamic Function 0

End of function make

End of class Super.

Class Child:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/lk4i0
function name:  __construct
number of ops:  4
compiled vars:  !0 = $something
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    4     0  E >   RECV                                                 !0      
    6     1        ASSIGN_OBJ                                                   'something'
          2        OP_DATA                                                      !0
    7     3      > RETURN                                                       null

End of function __construct

Function make:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/lk4i0
function name:  make
number of ops:  8
compiled vars:  !0 = $array
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    9     0  E >   RECV                                                 !0      
   11     1        INIT_FCALL                                                   'array_map'
          2        DECLARE_LAMBDA_FUNCTION                              ~1      [0]
   13     3        SEND_VAL                                                     ~1
          4        SEND_VAR                                                     !0
   11     5        DO_ICALL                                             $2      
   13     6      > RETURN                                                       $2
   14     7*     > RETURN                                                       null


Dynamic Functions:
Dynamic Function 0
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/lk4i0
function name:  {closure:Super::make():11}
number of ops:  6
compiled vars:  !0 = $el
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   11     0  E >   RECV                                                 !0      
   12     1        NEW                              static              $1      
          2        SEND_VAR_EX                                                  !0
          3        DO_FCALL                                          0          
          4      > RETURN                                                       $1
   13     5*     > RETURN                                                       null

End of Dynamic Function 0

End of function make

End of class Child.

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
180.4 ms | 2441 KiB | 16 Q