3v4l.org

run code in 300+ PHP versions simultaneously
<?php $k = 'phone'; $v = '(555) 555-1212)'; $result[$k] = preg_replace('/[^0-9]/', '', $v); echo $result[$k];
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/IieRK
function name:  (null)
number of ops:  12
compiled vars:  !0 = $k, !1 = $v, !2 = $result
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'phone'
          1        ASSIGN                                                   !1, '%28555%29+555-1212%29'
    4     2        INIT_FCALL                                               'preg_replace'
          3        SEND_VAL                                                 '%2F%5B%5E0-9%5D%2F'
          4        SEND_VAL                                                 ''
          5        SEND_VAR                                                 !1
          6        DO_ICALL                                         $6      
          7        ASSIGN_DIM                                               !2, !0
          8        OP_DATA                                                  $6
    6     9        FETCH_DIM_R                                      ~7      !2, !0
         10        ECHO                                                     ~7
         11      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
152.34 ms | 1394 KiB | 15 Q