3v4l.org

run code in 300+ PHP versions simultaneously
<?php $user_email = 'asd@toyota.com'; $re_to = "[^@]+@[^@]"; //"[^@]+@[^@]*toyota[^@]*\.[^@]+"; $regex = preg_quote($re_to); $res = preg_match($regex, $user_email); echo $res ? '1' : '0';
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 12, Position 2 = 14
Branch analysis from position: 12
1 jumps found. (Code = 42) Position 1 = 15
Branch analysis from position: 15
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 14
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/jFNWi
function name:  (null)
number of ops:  17
compiled vars:  !0 = $user_email, !1 = $re_to, !2 = $regex, !3 = $res
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   ASSIGN                                                   !0, 'asd%40toyota.com'
    7     1        ASSIGN                                                   !1, '%5B%5E%40%5D%2B%40%5B%5E%40%5D'
    9     2        INIT_FCALL                                               'preg_quote'
          3        SEND_VAR                                                 !1
          4        DO_ICALL                                         $6      
          5        ASSIGN                                                   !2, $6
   11     6        INIT_FCALL                                               'preg_match'
          7        SEND_VAR                                                 !2
          8        SEND_VAR                                                 !0
          9        DO_ICALL                                         $8      
         10        ASSIGN                                                   !3, $8
   13    11      > JMPZ                                                     !3, ->14
         12    >   QM_ASSIGN                                        ~10     '1'
         13      > JMP                                                      ->15
         14    >   QM_ASSIGN                                        ~10     '0'
         15    >   ECHO                                                     ~10
         16      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.16 ms | 1395 KiB | 17 Q