3v4l.org

run code in 500+ PHP versions simultaneously
<?php $className = 'getADog'; $result = strtolower(preg_replace('/[a-zA-Z]\K(?=[A-Z])/', '-', $className)); echo $result;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/auZ5F
function name:  (null)
number of ops:  9
compiled vars:  !0 = $className, !1 = $result
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                       !0, 'getADog'
    4     1        INIT_FCALL                                                   'strtolower'
          2        FRAMELESS_ICALL_3                preg_replace        ~3      '%2F%5Ba-zA-Z%5D%5CK%28%3F%3D%5BA-Z%5D%29%2F', '-'
          3        OP_DATA                                                      !0
          4        SEND_VAL                                                     ~3
          5        DO_ICALL                                             $4      
          6        ASSIGN                                                       !1, $4
    5     7        ECHO                                                         !1
    6     8      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
177.53 ms | 1583 KiB | 14 Q