3v4l.org

run code in 500+ PHP versions simultaneously
<?php $paths = array( 20 => array( 'name' => 'Heels', 'path' => '1/2/10/15/20', ), 15 => array( 'name' => 'Sandals', 'path' => '1/2/80/96/15', ), 10 => array( 'name' => 'Trainers', 'path' => '1/2/80/96/10', ), ); arsort($paths); $breadcrumb = (object) array( 'value' => array_keys($paths)[count($paths)-1], 'labels' => implode(' > ', array_column($paths, 'name')) ); var_dump($breadcrumb);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/1lndS
function name:  (null)
number of ops:  23
compiled vars:  !0 = $paths, !1 = $breadcrumb
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                       !0, <array>
   21     1        INIT_FCALL                                                   'arsort'
          2        SEND_REF                                                     !0
          3        DO_ICALL                                                     
   24     4        INIT_FCALL                                                   'array_keys'
          5        SEND_VAR                                                     !0
          6        DO_ICALL                                             $4      
          7        COUNT                                                ~5      !0
          8        SUB                                                  ~6      ~5, 1
          9        FETCH_DIM_R                                          ~7      $4, ~6
         10        INIT_ARRAY                                           ~8      ~7, 'value'
   25    11        INIT_FCALL                                                   'array_column'
         12        SEND_VAR                                                     !0
         13        SEND_VAL                                                     'name'
         14        DO_ICALL                                             $9      
         15        FRAMELESS_ICALL_2                implode             ~10     '+%3E+', $9
         16        ADD_ARRAY_ELEMENT                                    ~8      ~10, 'labels'
         17        CAST                                              8  ~11     ~8
   23    18        ASSIGN                                                       !1, ~11
   28    19        INIT_FCALL                                                   'var_dump'
         20        SEND_VAR                                                     !1
         21        DO_ICALL                                                     
         22      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
157.53 ms | 2016 KiB | 17 Q