3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr = array('order_source' => 'google', 'order_medium' => 'google-text'); echo http_build_query($arr); function bqs($array, $qs='') { foreach($array as $par => $val) { if(is_array($val)) {echo "array hai"; exit; bqs($arr, $qs); } else { $qs .= $par.'='.$val.'&'; } } return $qs; } echo bqs($arr);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/VLUnt
function name:  (null)
number of ops:  10
compiled vars:  !0 = $arr
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    3     1        INIT_FCALL                                               'http_build_query'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $2      
          4        ECHO                                                     $2
   21     5        INIT_FCALL                                               'bqs'
          6        SEND_VAR                                                 !0
          7        DO_FCALL                                      0  $3      
          8        ECHO                                                     $3
          9      > RETURN                                                   1

Function bqs:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 3, Position 2 = 19
Branch analysis from position: 3
2 jumps found. (Code = 78) Position 1 = 4, Position 2 = 19
Branch analysis from position: 4
2 jumps found. (Code = 43) Position 1 = 7, Position 2 = 14
Branch analysis from position: 7
1 jumps found. (Code = 79) Position 1 = -2
Branch analysis from position: 14
1 jumps found. (Code = 42) Position 1 = 3
Branch analysis from position: 3
Branch analysis from position: 19
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 19
filename:       /in/VLUnt
function name:  bqs
number of ops:  22
compiled vars:  !0 = $array, !1 = $qs, !2 = $val, !3 = $par, !4 = $arr
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   RECV                                             !0      
          1        RECV_INIT                                        !1      ''
    7     2      > FE_RESET_R                                       $5      !0, ->19
          3    > > FE_FETCH_R                                       ~6      $5, !2, ->19
          4    >   ASSIGN                                                   !3, ~6
    9     5        TYPE_CHECK                                  128          !2
          6      > JMPZ                                                     ~8, ->14
   10     7    >   ECHO                                                     'array+hai'
          8      > EXIT                                                     
   11     9*       INIT_FCALL_BY_NAME                                       'bqs'
         10*       SEND_VAR_EX                                              !4
         11*       SEND_VAR_EX                                              !1
         12*       DO_FCALL                                      0          
         13*       JMP                                                      ->18
   15    14    >   CONCAT                                           ~10     !3, '%3D'
         15        CONCAT                                           ~11     ~10, !2
         16        CONCAT                                           ~12     ~11, '%26'
         17        ASSIGN_OP                                     8          !1, ~12
    7    18      > JMP                                                      ->3
         19    >   FE_FREE                                                  $5
   18    20      > RETURN                                                   !1
   19    21*     > RETURN                                                   null

End of function bqs

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
177.25 ms | 1399 KiB | 16 Q