3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = "C#maj7"; $qualityVal = ""; if (true) { $qualityVal .= substr($string, 2); } $num = 10; $num += 10; class Hello { public $world; public function __toString() { return "Hello!"; } } $hello = new Hello(); //$world = "world"; //echo $hello->$world; $hello->world = "world"; if ($hello->world) { echo "Hello!"; } else { echo "No!"; } ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 3, Position 2 = 8
Branch analysis from position: 3
2 jumps found. (Code = 43) Position 1 = 18, Position 2 = 20
Branch analysis from position: 18
1 jumps found. (Code = 42) Position 1 = 21
Branch analysis from position: 21
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 20
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 8
filename:       /in/XsKkr
function name:  (null)
number of ops:  22
compiled vars:  !0 = $string, !1 = $qualityVal, !2 = $num, !3 = $hello
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'C%23maj7'
    3     1        ASSIGN                                                   !1, ''
    4     2      > JMPZ                                                     <true>, ->8
    5     3    >   INIT_FCALL                                               'substr'
          4        SEND_VAR                                                 !0
          5        SEND_VAL                                                 2
          6        DO_ICALL                                         $6      
          7        ASSIGN_OP                                     8          !1, $6
    7     8    >   ASSIGN                                                   !2, 10
    8     9        ASSIGN_OP                                     1          !2, 10
    9    10        DECLARE_CLASS                                            'hello'
   15    11        NEW                                              $10     'Hello'
         12        DO_FCALL                                      0          
         13        ASSIGN                                                   !3, $10
   18    14        ASSIGN_OBJ                                               !3, 'world'
         15        OP_DATA                                                  'world'
   19    16        FETCH_OBJ_R                                      ~14     !3, 'world'
         17      > JMPZ                                                     ~14, ->20
   20    18    >   ECHO                                                     'Hello%21'
         19      > JMP                                                      ->21
   23    20    >   ECHO                                                     'No%21'
   25    21    > > RETURN                                                   1

Class Hello:
Function __tostring:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/XsKkr
function name:  __toString
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E > > RETURN                                                   'Hello%21'
   13     1*       VERIFY_RETURN_TYPE                                       
          2*     > RETURN                                                   null

End of function __tostring

End of class Hello.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
156.87 ms | 1388 KiB | 15 Q