3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr = array ( 10 => array('id' => 'dix', 'aa' => '1010'), 100 => array('id' => 'cent', 'aa' => '100100'), 2 => array('id' => 'deux', 'aa' => '22'), 7 => array('id' => 'sept', 'aa' => '77')); // id sorting function so ($a, $b) { return (strcmp ($a['id'],$b['id'])); } echo uasort($arr, 'so'); ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/7rmTp
function name:  (null)
number of ops:  7
compiled vars:  !0 = $arr
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    9     1        INIT_FCALL                                               'uasort'
          2        SEND_REF                                                 !0
          3        SEND_VAL                                                 'so'
          4        DO_ICALL                                         $2      
          5        ECHO                                                     $2
   10     6      > RETURN                                                   1

Function so:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/7rmTp
function name:  so
number of ops:  10
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        INIT_FCALL                                               'strcmp'
          3        FETCH_DIM_R                                      ~2      !0, 'id'
          4        SEND_VAL                                                 ~2
          5        FETCH_DIM_R                                      ~3      !1, 'id'
          6        SEND_VAL                                                 ~3
          7        DO_ICALL                                         $4      
          8      > RETURN                                                   $4
          9*     > RETURN                                                   null

End of function so

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
143.91 ms | 1395 KiB | 17 Q