3v4l.org

run code in 300+ PHP versions simultaneously
<?php $target = "abcwa"; echo preg_replace('/./', 'w:$0', $target); echo "\n"; echo preg_replace('/(?=.)/', 'w:', $target);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/lPQVR
function name:  (null)
number of ops:  15
compiled vars:  !0 = $target
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'abcwa'
    5     1        INIT_FCALL                                               'preg_replace'
          2        SEND_VAL                                                 '%2F.%2F'
          3        SEND_VAL                                                 'w%3A%240'
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                         $2      
          6        ECHO                                                     $2
    7     7        ECHO                                                     '%0A'
    9     8        INIT_FCALL                                               'preg_replace'
          9        SEND_VAL                                                 '%2F%28%3F%3D.%29%2F'
         10        SEND_VAL                                                 'w%3A'
         11        SEND_VAR                                                 !0
         12        DO_ICALL                                         $3      
         13        ECHO                                                     $3
         14      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
160.44 ms | 1009 KiB | 14 Q