3v4l.org

run code in 300+ PHP versions simultaneously
<?php $sql = array("inUserID" =>7250, "inCustID" =>15319, "btAll" => "True", "btPermPref" => "True", "inDisplay"=>0); function pram_alter($array, $key) { //echo implode(',', each($array)); reset($array); $pStr=null; $sqlStatment=null; $bound = count($array); $endSqlStatement = ";"; while (list($key, $val) = each($array)) { //echo "$key => $val"; $pStr=$pStr."$key ='" . $val . "',"; $strproc='myProc'; $sqlStatment="exec " . $strproc . " " . $pStr; } $sqlStatment =$sqlStatment. $endSqlStatement; echo $bound; return $sqlStatment; } $temp=pram_alter($sql, 'pram_alter'); echo $temp; ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/nfiLT
function name:  (null)
number of ops:  8
compiled vars:  !0 = $sql, !1 = $temp
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
   25     1        INIT_FCALL                                               'pram_alter'
          2        SEND_VAR                                                 !0
          3        SEND_VAL                                                 'pram_alter'
          4        DO_FCALL                                      0  $3      
          5        ASSIGN                                                   !1, $3
   26     6        ECHO                                                     !1
   27     7      > RETURN                                                   1

Function pram_alter:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 22
Branch analysis from position: 22
2 jumps found. (Code = 44) Position 1 = 30, Position 2 = 11
Branch analysis from position: 30
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 11
2 jumps found. (Code = 44) Position 1 = 30, Position 2 = 11
Branch analysis from position: 30
Branch analysis from position: 11
filename:       /in/nfiLT
function name:  pram_alter
number of ops:  35
compiled vars:  !0 = $array, !1 = $key, !2 = $pStr, !3 = $sqlStatment, !4 = $bound, !5 = $endSqlStatement, !6 = $val, !7 = $strproc
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    7     2        INIT_FCALL                                               'reset'
          3        SEND_REF                                                 !0
          4        DO_ICALL                                                 
    8     5        ASSIGN                                                   !2, null
    9     6        ASSIGN                                                   !3, null
   10     7        COUNT                                            ~11     !0
          8        ASSIGN                                                   !4, ~11
   11     9        ASSIGN                                                   !5, '%3B'
   12    10      > JMP                                                      ->22
   15    11    >   NOP                                                      
         12        FAST_CONCAT                                      ~14     !1, '+%3D%27'
         13        CONCAT                                           ~15     !2, ~14
         14        CONCAT                                           ~16     ~15, !6
         15        CONCAT                                           ~17     ~16, '%27%2C'
         16        ASSIGN                                                   !2, ~17
   16    17        ASSIGN                                                   !7, 'myProc'
   17    18        CONCAT                                           ~20     'exec+', !7
         19        CONCAT                                           ~21     ~20, '+'
         20        CONCAT                                           ~22     ~21, !2
         21        ASSIGN                                                   !3, ~22
   12    22    >   INIT_FCALL_BY_NAME                                       'each'
         23        SEND_VAR_EX                                              !0
         24        DO_FCALL                                      0  $24     
         25        FETCH_LIST_R                                     $25     $24, 0
         26        ASSIGN                                                   !1, $25
         27        FETCH_LIST_R                                     $27     $24, 1
         28        ASSIGN                                                   !6, $27
         29      > JMPNZ                                                    $24, ->11
   19    30    >   CONCAT                                           ~29     !3, !5
         31        ASSIGN                                                   !3, ~29
   21    32        ECHO                                                     !4
   22    33      > RETURN                                                   !3
   23    34*     > RETURN                                                   null

End of function pram_alter

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
163.13 ms | 1403 KiB | 16 Q