3v4l.org

run code in 300+ PHP versions simultaneously
<?php $params = array('a', 'b', 'c'); $patterns = array_fill(0, count($params), '#\?#'); $replacements = $params; var_dump(preg_replace($patterns, $replacements, 'bla ? bla ? bla ? blu'), 1);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/nhpu2
function name:  (null)
number of ops:  19
compiled vars:  !0 = $params, !1 = $patterns, !2 = $replacements
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    4     1        INIT_FCALL                                               'array_fill'
          2        SEND_VAL                                                 0
          3        COUNT                                            ~4      !0
          4        SEND_VAL                                                 ~4
          5        SEND_VAL                                                 '%23%5C%3F%23'
          6        DO_ICALL                                         $5      
          7        ASSIGN                                                   !1, $5
    5     8        ASSIGN                                                   !2, !0
    6     9        INIT_FCALL                                               'var_dump'
         10        INIT_FCALL                                               'preg_replace'
         11        SEND_VAR                                                 !1
         12        SEND_VAR                                                 !2
         13        SEND_VAL                                                 'bla+%3F+bla+%3F+bla+%3F+blu'
         14        DO_ICALL                                         $8      
         15        SEND_VAR                                                 $8
         16        SEND_VAL                                                 1
         17        DO_ICALL                                                 
         18      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
162.51 ms | 1394 KiB | 19 Q