3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str = 'abcd,abed,abfd,abgd'; if(preg_match("/ab.d/",$str ,$matches) !== false){ // check any match found or not echo "match found:".$matches[0]; // when found print that match }//after printing execution will stops successfully. ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 8, Position 2 = 11
Branch analysis from position: 8
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 11
filename:       /in/bErZL
function name:  (null)
number of ops:  12
compiled vars:  !0 = $str, !1 = $matches
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'abcd%2Cabed%2Cabfd%2Cabgd'
    4     1        INIT_FCALL                                               'preg_match'
          2        SEND_VAL                                                 '%2Fab.d%2F'
          3        SEND_VAR                                                 !0
          4        SEND_REF                                                 !1
          5        DO_ICALL                                         $3      
          6        TYPE_CHECK                                  1018          $3
          7      > JMPZ                                                     ~4, ->11
    5     8    >   FETCH_DIM_R                                      ~5      !1, 0
          9        CONCAT                                           ~6      'match+found%3A', ~5
         10        ECHO                                                     ~6
    7    11    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
150.93 ms | 1398 KiB | 15 Q