3v4l.org

run code in 300+ PHP versions simultaneously
<?php $exception = ['will not'=>'will&nbspnot']; $string = 'I will not go'; $str = strtr($str, $exception); $array = explde(' ', $str); var_dump($array); var_dump(array_replace($array, $exception));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/2QbtL
function name:  (null)
number of ops:  23
compiled vars:  !0 = $exception, !1 = $string, !2 = $str, !3 = $array
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    4     1        ASSIGN                                                   !1, 'I+will+not+go'
    5     2        INIT_FCALL                                               'strtr'
          3        SEND_VAR                                                 !2
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                         $6      
          6        ASSIGN                                                   !2, $6
    6     7        INIT_FCALL_BY_NAME                                       'explde'
          8        SEND_VAL_EX                                              '+'
          9        SEND_VAR_EX                                              !2
         10        DO_FCALL                                      0  $8      
         11        ASSIGN                                                   !3, $8
    7    12        INIT_FCALL                                               'var_dump'
         13        SEND_VAR                                                 !3
         14        DO_ICALL                                                 
    8    15        INIT_FCALL                                               'var_dump'
         16        INIT_FCALL                                               'array_replace'
         17        SEND_VAR                                                 !3
         18        SEND_VAR                                                 !0
         19        DO_ICALL                                         $11     
         20        SEND_VAR                                                 $11
         21        DO_ICALL                                                 
         22      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
168.37 ms | 1395 KiB | 19 Q