3v4l.org

run code in 300+ PHP versions simultaneously
<?php declare(strict_types = 1); class ArrayWalk { public function withObject() { $object = (object)['foo' => 'bar']; array_walk($object, function ($v) { return '_' . $v; }); } } (new ArrayWalk())->withObject();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/E36RP
function name:  (null)
number of ops:  5
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   14     0  E >   NEW                                              $0      'ArrayWalk'
          1        DO_FCALL                                      0          
          2        INIT_METHOD_CALL                                         $0, 'withObject'
          3        DO_FCALL                                      0          
          4      > RETURN                                                   1

Class ArrayWalk:
Function withobject:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/E36RP
function name:  withObject
number of ops:  8
compiled vars:  !0 = $object
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   CAST                                          8  ~1      <array>
          1        ASSIGN                                                   !0, ~1
    8     2        INIT_FCALL                                               'array_walk'
          3        SEND_REF                                                 !0
          4        DECLARE_LAMBDA_FUNCTION                          ~3      [0]
   10     5        SEND_VAL                                                 ~3
    8     6        DO_ICALL                                                 
   11     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/E36RP
function name:  {closure}
number of ops:  4
compiled vars:  !0 = $v
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   RECV                                             !0      
    9     1        CONCAT                                           ~1      '_', !0
          2      > RETURN                                                   ~1
   10     3*     > RETURN                                                   null

End of Dynamic Function 0

End of function withobject

End of class ArrayWalk.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
137.66 ms | 997 KiB | 14 Q