3v4l.org

run code in 300+ PHP versions simultaneously
<?php $input = 'color=blue,red,weight=100kg,another=one,two,three,four,okay=enough,'; var_export(preg_split('~,(?=[^,]+=)~', rtrim($input, ','), 0, PREG_SPLIT_NO_EMPTY));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ko2Mf
function name:  (null)
number of ops:  15
compiled vars:  !0 = $input
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'color%3Dblue%2Cred%2Cweight%3D100kg%2Canother%3Done%2Ctwo%2Cthree%2Cfour%2Cokay%3Denough%2C'
    4     1        INIT_FCALL                                               'var_export'
          2        INIT_FCALL                                               'preg_split'
          3        SEND_VAL                                                 '%7E%2C%28%3F%3D%5B%5E%2C%5D%2B%3D%29%7E'
          4        INIT_FCALL                                               'rtrim'
          5        SEND_VAR                                                 !0
          6        SEND_VAL                                                 '%2C'
          7        DO_ICALL                                         $2      
          8        SEND_VAR                                                 $2
          9        SEND_VAL                                                 0
         10        SEND_VAL                                                 1
         11        DO_ICALL                                         $3      
         12        SEND_VAR                                                 $3
         13        DO_ICALL                                                 
         14      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
140.63 ms | 1433 KiB | 16 Q