3v4l.org

run code in 300+ PHP versions simultaneously
<?php $tokens = token_get_all('<?php $a = 1 + 2; echo $a ?>'); var_dump($tokens); foreach($tokens as $token) { echo $token[0]; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 8, Position 2 = 12
Branch analysis from position: 8
2 jumps found. (Code = 78) Position 1 = 9, Position 2 = 12
Branch analysis from position: 9
1 jumps found. (Code = 42) Position 1 = 8
Branch analysis from position: 8
Branch analysis from position: 12
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 12
filename:       /in/4aOeK
function name:  (null)
number of ops:  14
compiled vars:  !0 = $tokens, !1 = $token
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'token_get_all'
          1        SEND_VAL                                                 '%3C%3Fphp+%24a+%3D+1+%2B+2%3B+echo+%24a+%3F%3E'
          2        DO_ICALL                                         $2      
          3        ASSIGN                                                   !0, $2
    4     4        INIT_FCALL                                               'var_dump'
          5        SEND_VAR                                                 !0
          6        DO_ICALL                                                 
    5     7      > FE_RESET_R                                       $5      !0, ->12
          8    > > FE_FETCH_R                                               $5, !1, ->12
    6     9    >   FETCH_DIM_R                                      ~6      !1, 0
         10        ECHO                                                     ~6
    5    11      > JMP                                                      ->8
         12    >   FE_FREE                                                  $5
    7    13      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
174.17 ms | 1386 KiB | 17 Q