3v4l.org

run code in 300+ PHP versions simultaneously
<?php $lol = array ( 0 => array ( 'for' => '$T4', 'deps' => array ( 0 => '$T3', ), ), 1 => array ( 'for' => '$T3', 'deps' => array ( 0 => '$T2', ), ), 2 => array ( 'for' => '$T1', 'deps' => array ( ), ), 3 => array ( 'for' => '$T2', 'deps' => array ( 0 => '$T1', ), ), ); uasort($lol, function($a, $b){ return in_array($a['for'], $b['deps']) ? -1 : 1; }); var_dump($lol);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/pXIZV
function name:  (null)
number of ops:  10
compiled vars:  !0 = $lol
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
   39     1        INIT_FCALL                                               'uasort'
          2        SEND_REF                                                 !0
          3        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FpXIZV%3A39%240'
   41     4        SEND_VAL                                                 ~2
          5        DO_ICALL                                                 
   44     6        INIT_FCALL                                               'var_dump'
          7        SEND_VAR                                                 !0
          8        DO_ICALL                                                 
          9      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2FpXIZV%3A39%240:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 9, Position 2 = 11
Branch analysis from position: 9
1 jumps found. (Code = 42) Position 1 = 12
Branch analysis from position: 12
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 11
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/pXIZV
function name:  {closure}
number of ops:  14
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   39     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   40     2        INIT_FCALL                                               'in_array'
          3        FETCH_DIM_R                                      ~2      !0, 'for'
          4        SEND_VAL                                                 ~2
          5        FETCH_DIM_R                                      ~3      !1, 'deps'
          6        SEND_VAL                                                 ~3
          7        DO_ICALL                                         $4      
          8      > JMPZ                                                     $4, ->11
          9    >   QM_ASSIGN                                        ~5      -1
         10      > JMP                                                      ->12
         11    >   QM_ASSIGN                                        ~5      1
         12    > > RETURN                                                   ~5
   41    13*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FpXIZV%3A39%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
160.2 ms | 1396 KiB | 19 Q