3v4l.org

run code in 300+ PHP versions simultaneously
<?php class FooClass {} $foo = new FooClass(); $foo->bar = "qux"; $thing = "bar"; $qux = "th"; $grault = "ing"; function th($waldo){ global $qux, $grault, $thing; return ${$qux . $grault} . $waldo; } echo ${($foo->${${$foo->bar}.((${qux}.${grault}===$qux.${grault})?${grault}:${$qux.$grault})})}(($foo->${${$foo->bar}.((${qux}.${grault}===$qux.${grault})?${grault}:${$qux.$grault})})); // echos 'barqux'
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 20, Position 2 = 24
Branch analysis from position: 20
1 jumps found. (Code = 42) Position 1 = 27
Branch analysis from position: 27
2 jumps found. (Code = 43) Position 1 = 45, Position 2 = 49
Branch analysis from position: 45
1 jumps found. (Code = 42) Position 1 = 52
Branch analysis from position: 52
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 49
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 24
2 jumps found. (Code = 43) Position 1 = 45, Position 2 = 49
Branch analysis from position: 45
Branch analysis from position: 49
filename:       /in/glWB6
function name:  (null)
number of ops:  59
compiled vars:  !0 = $foo, !1 = $thing, !2 = $qux, !3 = $grault
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   NEW                                              $4      'FooClass'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $4
    4     3        ASSIGN_OBJ                                               !0, 'bar'
          4        OP_DATA                                                  'qux'
    5     5        ASSIGN                                                   !1, 'bar'
    6     6        ASSIGN                                                   !2, 'th'
    7     7        ASSIGN                                                   !3, 'ing'
   14     8        FETCH_OBJ_R                                      ~11     !0, 'bar'
          9        FETCH_R                      local               ~12     ~11
         10        FETCH_CONSTANT                                   ~13     'qux'
         11        FETCH_R                      local               ~14     ~13
         12        FETCH_CONSTANT                                   ~15     'grault'
         13        FETCH_R                      local               ~16     ~15
         14        CONCAT                                           ~17     ~14, ~16
         15        FETCH_CONSTANT                                   ~18     'grault'
         16        FETCH_R                      local               ~19     ~18
         17        CONCAT                                           ~20     !2, ~19
         18        IS_IDENTICAL                                             ~17, ~20
         19      > JMPZ                                                     ~21, ->24
         20    >   FETCH_CONSTANT                                   ~22     'grault'
         21        FETCH_R                      local               ~23     ~22
         22        QM_ASSIGN                                        ~24     ~23
         23      > JMP                                                      ->27
         24    >   CONCAT                                           ~25     !2, !3
         25        FETCH_R                      local               ~26     ~25
         26        QM_ASSIGN                                        ~24     ~26
         27    >   CONCAT                                           ~27     ~12, ~24
         28        FETCH_R                      local               ~28     ~27
         29        FETCH_OBJ_R                                      ~29     !0, ~28
         30        FETCH_R                      local               ~30     ~29
         31        INIT_DYNAMIC_CALL                                        ~30
         32        CHECK_FUNC_ARG                                           
         33        FETCH_OBJ_R                                      ~31     !0, 'bar'
         34        FETCH_R                      local               ~32     ~31
         35        FETCH_CONSTANT                                   ~33     'qux'
         36        FETCH_R                      local               ~34     ~33
         37        FETCH_CONSTANT                                   ~35     'grault'
         38        FETCH_R                      local               ~36     ~35
         39        CONCAT                                           ~37     ~34, ~36
         40        FETCH_CONSTANT                                   ~38     'grault'
         41        FETCH_R                      local               ~39     ~38
         42        CONCAT                                           ~40     !2, ~39
         43        IS_IDENTICAL                                             ~37, ~40
         44      > JMPZ                                                     ~41, ->49
         45    >   FETCH_CONSTANT                                   ~42     'grault'
         46        FETCH_R                      local               ~43     ~42
         47        QM_ASSIGN                                        ~44     ~43
         48      > JMP                                                      ->52
         49    >   CONCAT                                           ~45     !2, !3
         50        FETCH_R                      local               ~46     ~45
         51        QM_ASSIGN                                        ~44     ~46
         52    >   CONCAT                                           ~47     ~32, ~44
         53        FETCH_R                      local               ~48     ~47
         54        FETCH_OBJ_FUNC_ARG                               $49     !0, ~48
         55        SEND_FUNC_ARG                                            $49
         56        DO_FCALL                                      0  $50     
         57        ECHO                                                     $50
   16    58      > RETURN                                                   1

Function th:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/glWB6
function name:  th
number of ops:  9
compiled vars:  !0 = $waldo, !1 = $qux, !2 = $grault, !3 = $thing
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   RECV                                             !0      
   10     1        BIND_GLOBAL                                              !1, 'qux'
          2        BIND_GLOBAL                                              !2, 'grault'
          3        BIND_GLOBAL                                              !3, 'thing'
   11     4        CONCAT                                           ~4      !1, !2
          5        FETCH_R                      local               ~5      ~4
          6        CONCAT                                           ~6      ~5, !0
          7      > RETURN                                                   ~6
   12     8*     > RETURN                                                   null

End of function th

Class FooClass: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
165.63 ms | 944 KiB | 14 Q