3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Something { public function __construct() { $this->current_user = Auth::get_user(); } public function another_thing() { $groups = array_filter(array(0, 1, 5, 10, 50), function($item) { return $item < $this->current_user->group; }); } } Something::another_thing();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/uhRZi
function name:  (null)
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   18     0  E >   INIT_STATIC_METHOD_CALL                                  'Something', 'another_thing'
          1        DO_FCALL                                      0          
          2      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2FuhRZi%3A12%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/uhRZi
function name:  {closure}
number of ops:  7
compiled vars:  !0 = $item
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   RECV                                             !0      
   13     1        FETCH_THIS                                       $1      
          2        FETCH_OBJ_R                                      ~2      $1, 'current_user'
          3        FETCH_OBJ_R                                      ~3      ~2, 'group'
          4        IS_SMALLER                                       ~4      !0, ~3
          5      > RETURN                                                   ~4
   14     6*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FuhRZi%3A12%240

Class Something:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/uhRZi
function name:  __construct
number of ops:  5
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   INIT_STATIC_METHOD_CALL                                  'Auth', 'get_user'
          1        DO_FCALL                                      0  $1      
          2        ASSIGN_OBJ                                               'current_user'
          3        OP_DATA                                                  $1
    8     4      > RETURN                                                   null

End of function __construct

Function another_thing:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/uhRZi
function name:  another_thing
number of ops:  7
compiled vars:  !0 = $groups
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   INIT_FCALL                                               'array_filter'
          1        SEND_VAL                                                 <array>
          2        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FuhRZi%3A12%240'
   14     3        SEND_VAL                                                 ~1
          4        DO_ICALL                                         $2      
   12     5        ASSIGN                                                   !0, $2
   15     6      > RETURN                                                   null

End of function another_thing

End of class Something.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
147.96 ms | 1396 KiB | 15 Q