3v4l.org

run code in 500+ PHP versions simultaneously
<?php function ccbreaker(string $input): string { return preg_replace_callback( '/[A-Z]/', fn (array $match): string => ' '. chr(ord($match[0]) + 32), $input ); } echo ccbreaker("policeSiren"). PHP_EOL; echo ccbreaker("camelCasingTest") . PHP_EOL;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/1vCqj
function name:  (null)
number of ops:  11
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   11     0  E >   INIT_FCALL                                                   'ccbreaker'
          1        SEND_VAL                                                     'policeSiren'
          2        DO_FCALL                                          0  $0      
          3        CONCAT                                               ~1      $0, '%0A'
          4        ECHO                                                         ~1
   12     5        INIT_FCALL                                                   'ccbreaker'
          6        SEND_VAL                                                     'camelCasingTest'
          7        DO_FCALL                                          0  $2      
          8        CONCAT                                               ~3      $2, '%0A'
          9        ECHO                                                         ~3
   13    10      > RETURN                                                       1

Function ccbreaker:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/1vCqj
function name:  ccbreaker
number of ops:  11
compiled vars:  !0 = $input
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   RECV                                                 !0      
    4     1        INIT_FCALL                                                   'preg_replace_callback'
    5     2        SEND_VAL                                                     '%2F%5BA-Z%5D%2F'
    6     3        DECLARE_LAMBDA_FUNCTION                              ~1      [0]
          4        SEND_VAL                                                     ~1
    7     5        SEND_VAR                                                     !0
    4     6        DO_ICALL                                             $2      
    7     7        VERIFY_RETURN_TYPE                                           $2
          8      > RETURN                                                       $2
    9     9*       VERIFY_RETURN_TYPE                                           
         10*     > RETURN                                                       null


Dynamic Functions:
Dynamic Function 0
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/1vCqj
function name:  {closure:ccbreaker():6}
number of ops:  14
compiled vars:  !0 = $match
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    6     0  E >   RECV                                                 !0      
          1        INIT_FCALL                                                   'chr'
          2        INIT_FCALL                                                   'ord'
          3        FETCH_DIM_R                                          ~1      !0, 0
          4        SEND_VAL                                                     ~1
          5        DO_ICALL                                             $2      
          6        ADD                                                  ~3      $2, 32
          7        SEND_VAL                                                     ~3
          8        DO_ICALL                                             $4      
          9        CONCAT                                               ~5      '+', $4
         10        VERIFY_RETURN_TYPE                                           ~5
         11      > RETURN                                                       ~5
         12*       VERIFY_RETURN_TYPE                                           
         13*     > RETURN                                                       null

End of Dynamic Function 0

End of function ccbreaker

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
233.23 ms | 2100 KiB | 18 Q