3v4l.org

run code in 500+ PHP versions simultaneously
<?php var_dump(preg_match('/^/', 'foo', $m)); var_dump($m); var_dump(preg_match('/\s*/', 'foo', $m)); var_dump($m); var_dump(preg_match('/\w+/', 'foo', $m)); var_dump($m); var_dump(preg_match('/$/', 'foo', $m)); var_dump($m);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/bHAla
function name:  (null)
number of ops:  45
compiled vars:  !0 = $m
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                                   'var_dump'
          1        INIT_FCALL                                                   'preg_match'
          2        SEND_VAL                                                     '%2F%5E%2F'
          3        SEND_VAL                                                     'foo'
          4        SEND_REF                                                     !0
          5        DO_ICALL                                             $1      
          6        SEND_VAR                                                     $1
          7        DO_ICALL                                                     
    4     8        INIT_FCALL                                                   'var_dump'
          9        SEND_VAR                                                     !0
         10        DO_ICALL                                                     
    6    11        INIT_FCALL                                                   'var_dump'
         12        INIT_FCALL                                                   'preg_match'
         13        SEND_VAL                                                     '%2F%5Cs%2A%2F'
         14        SEND_VAL                                                     'foo'
         15        SEND_REF                                                     !0
         16        DO_ICALL                                             $4      
         17        SEND_VAR                                                     $4
         18        DO_ICALL                                                     
    7    19        INIT_FCALL                                                   'var_dump'
         20        SEND_VAR                                                     !0
         21        DO_ICALL                                                     
    9    22        INIT_FCALL                                                   'var_dump'
         23        INIT_FCALL                                                   'preg_match'
         24        SEND_VAL                                                     '%2F%5Cw%2B%2F'
         25        SEND_VAL                                                     'foo'
         26        SEND_REF                                                     !0
         27        DO_ICALL                                             $7      
         28        SEND_VAR                                                     $7
         29        DO_ICALL                                                     
   10    30        INIT_FCALL                                                   'var_dump'
         31        SEND_VAR                                                     !0
         32        DO_ICALL                                                     
   12    33        INIT_FCALL                                                   'var_dump'
         34        INIT_FCALL                                                   'preg_match'
         35        SEND_VAL                                                     '%2F%24%2F'
         36        SEND_VAL                                                     'foo'
         37        SEND_REF                                                     !0
         38        DO_ICALL                                             $10     
         39        SEND_VAR                                                     $10
         40        DO_ICALL                                                     
   13    41        INIT_FCALL                                                   'var_dump'
         42        SEND_VAR                                                     !0
         43        DO_ICALL                                                     
         44      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
169.74 ms | 2454 KiB | 15 Q