3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = 'a@-b.cd'; $pattern = '/[a-z0-9_\-\+\.]+@[a-z0-9\-]+\.([a-z]{2,4})(?:\.[a-z]{2})?/i'; preg_match_all($pattern, $string , $matches); var_dump($matches[0]);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/IRAke
function name:  (null)
number of ops:  12
compiled vars:  !0 = $string, !1 = $pattern, !2 = $matches
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'a%40-b.cd'
    4     1        ASSIGN                                                   !1, '%2F%5Ba-z0-9_%5C-%5C%2B%5C.%5D%2B%40%5Ba-z0-9%5C-%5D%2B%5C.%28%5Ba-z%5D%7B2%2C4%7D%29%28%3F%3A%5C.%5Ba-z%5D%7B2%7D%29%3F%2Fi'
    5     2        INIT_FCALL                                               'preg_match_all'
          3        SEND_VAR                                                 !1
          4        SEND_VAR                                                 !0
          5        SEND_REF                                                 !2
          6        DO_ICALL                                                 
    6     7        INIT_FCALL                                               'var_dump'
          8        FETCH_DIM_R                                      ~6      !2, 0
          9        SEND_VAL                                                 ~6
         10        DO_ICALL                                                 
         11      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
138.36 ms | 999 KiB | 15 Q