3v4l.org

run code in 300+ PHP versions simultaneously
<?php $data = <<< 'TEXT' edit 2 set dst 10.23.255.252 255.255.255.252 set device "abc" set comment "Static Route site-5552" TEXT; $match=[]; preg_match('/set dst ([\d\.]+).*site-5552/s',$data,$match); echo $match[1];
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Wrf6Q
function name:  (null)
number of ops:  10
compiled vars:  !0 = $data, !1 = $match
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'edit+2%0A++++++++set+dst+10.23.255.252+255.255.255.252%0A++++++++set+device+%22abc%22%0A++++++++set+comment+%22Static+Route+site-5552%22'
   10     1        ASSIGN                                                   !1, <array>
   11     2        INIT_FCALL                                               'preg_match'
          3        SEND_VAL                                                 '%2Fset+dst+%28%5B%5Cd%5C.%5D%2B%29.%2Asite-5552%2Fs'
          4        SEND_VAR                                                 !0
          5        SEND_REF                                                 !1
          6        DO_ICALL                                                 
   13     7        FETCH_DIM_R                                      ~5      !1, 1
          8        ECHO                                                     ~5
          9      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
185.62 ms | 1398 KiB | 15 Q