3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = ["[foo]:9","[2]:nice"]; foreach ($array as $v) { [$key, $result[$key]] = sscanf($v, '[%[^]]]:%s'); } var_export($result);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 2, Position 2 = 14
Branch analysis from position: 2
2 jumps found. (Code = 78) Position 1 = 3, Position 2 = 14
Branch analysis from position: 3
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 14
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 14
filename:       /in/UepBd
function name:  (null)
number of ops:  19
compiled vars:  !0 = $array, !1 = $v, !2 = $key, !3 = $result
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    4     1      > FE_RESET_R                                       $5      !0, ->14
          2    > > FE_FETCH_R                                               $5, !1, ->14
    5     3    >   INIT_FCALL                                               'sscanf'
          4        SEND_VAR                                                 !1
          5        SEND_VAL                                                 '%5B%25%5B%5E%5D%5D%5D%3A%25s'
          6        DO_ICALL                                         $6      
          7        FETCH_LIST_R                                     $7      $6, 0
          8        ASSIGN                                                   !2, $7
          9        FETCH_LIST_R                                     $9      $6, 1
         10        ASSIGN_DIM                                               !3, !2
         11        OP_DATA                                                  $9
         12        FREE                                                     $6
    4    13      > JMP                                                      ->2
         14    >   FE_FREE                                                  $5
    7    15        INIT_FCALL                                               'var_export'
         16        SEND_VAR                                                 !3
         17        DO_ICALL                                                 
         18      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
139.34 ms | 998 KiB | 15 Q