3v4l.org

run code in 500+ PHP versions simultaneously
<?php class Foop { public $abc = false; function foo() { static $a = $this->abc; static $b = $this->bar(); static $c = $this?->bar($this?->abc); static $d = function($a) { return $a * 10; }; static $e = fn($a) => $a * 10; static $f = ltrim(...); } function bar() {} }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Hm4Zq
function name:  (null)
number of ops:  1
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   16     0  E > > RETURN                                                       1

Class Foop:
Function foo:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Hm4Zq
function name:  foo
number of ops:  24
compiled vars:  !0 = $a, !1 = $b, !2 = $c, !3 = $d, !4 = $e, !5 = $f
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    7     0  E >   BIND_INIT_STATIC_OR_JMP                                      !0
          1        FETCH_OBJ_R                                          ~6      'abc'
          2        BIND_STATIC                                                  !0, ~6
    8     3        BIND_INIT_STATIC_OR_JMP                                      !1
          4        INIT_METHOD_CALL                                             'bar'
          5        DO_FCALL                                          0  $7      
          6        BIND_STATIC                                                  !1, $7
    9     7        BIND_INIT_STATIC_OR_JMP                                      !2
          8        INIT_METHOD_CALL                                             'bar'
          9        FETCH_OBJ_R                                          ~8      'abc'
         10        SEND_VAL_EX                                                  ~8
         11        DO_FCALL                                          0  $9      
         12        BIND_STATIC                                                  !2, $9
   10    13        BIND_INIT_STATIC_OR_JMP                                      !3
         14        DECLARE_LAMBDA_FUNCTION                              ~10     [0]
         15        BIND_STATIC                                                  !3, ~10
   11    16        BIND_INIT_STATIC_OR_JMP                                      !4
         17        DECLARE_LAMBDA_FUNCTION                              ~11     [1]
         18        BIND_STATIC                                                  !4, ~11
   12    19        BIND_INIT_STATIC_OR_JMP                                      !5
         20        INIT_FCALL                                                   'ltrim'
         21        CALLABLE_CONVERT                                     ~12     
         22        BIND_STATIC                                                  !5, ~12
   13    23      > 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/Hm4Zq
function name:  {closure:Foop::foo():10}
number of ops:  4
compiled vars:  !0 = $a
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   10     0  E >   RECV                                                 !0      
          1        MUL                                                  ~1      !0, 10
          2      > RETURN                                                       ~1
          3*     > RETURN                                                       null

End of Dynamic Function 0

Dynamic Function 1
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Hm4Zq
function name:  {closure:Foop::foo():11}
number of ops:  4
compiled vars:  !0 = $a
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   11     0  E >   RECV                                                 !0      
          1        MUL                                                  ~1      !0, 10
          2      > RETURN                                                       ~1
          3*     > RETURN                                                       null

End of Dynamic Function 1

End of function foo

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

End of function bar

End of class Foop.

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
157.49 ms | 1480 KiB | 14 Q