3v4l.org

run code in 500+ PHP versions simultaneously
<?php $array1 = [ ["B00CEEZ57S"], ["B002QJZADK"], ["B001EHL2UK"], ["B003FSTNB6"], ]; $array2 = [ [ "name" => "Jonathan Franzen: Purity (Hardcover); 2015 Edition", "ASIN" => "B002QJZADK" ], [ "name" => "Cardinal Gates Outdoor Child Safety Gate, Brown", "ASIN" => "B00CE8C7SO" ], [ "name" => "Sauder Edge Water 71.88\" Bookcase Estate Black Finish", "ASIN" => "B001EHL2UK" ], [ "name" => "The Pioneer Woman 82695.03R Cowboy Rustic 8\" Rosewood Handle Can Opener, Scis...", "ASIN" => "B015LU7GPU" ] ]; var_export( array_uintersect( $array2, $array1, fn($a, $b) => ($a['ASIN'] ?? $a[0]) <=> ($b['ASIN'] ?? $b[0]) ) );
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/8OjATc
function name:  (null)
number of ops:  12
compiled vars:  !0 = $array1, !1 = $array2
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                       !0, <array>
   10     1        ASSIGN                                                       !1, <array>
   29     2        INIT_FCALL                                                   'var_export'
   30     3        INIT_FCALL                                                   'array_uintersect'
   31     4        SEND_VAR                                                     !1
   32     5        SEND_VAR                                                     !0
   33     6        DECLARE_LAMBDA_FUNCTION                              ~4      [0]
   37     7        SEND_VAL                                                     ~4
   30     8        DO_ICALL                                             $5      
   37     9        SEND_VAR                                                     $5
   29    10        DO_ICALL                                                     
   38    11      > RETURN                                                       1


Dynamic Functions:
Dynamic Function 0
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/8OjATc
function name:  {closure:/in/8OjATc:33}
number of ops:  13
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   33     0  E >   RECV                                                 !0      
          1        RECV                                                 !1      
   34     2        FETCH_DIM_IS                                         ~2      !0, 'ASIN'
          3        COALESCE                                             ~3      ~2
          4        FETCH_DIM_R                                          ~4      !0, 0
          5        QM_ASSIGN                                            ~3      ~4
   36     6        FETCH_DIM_IS                                         ~5      !1, 'ASIN'
          7        COALESCE                                             ~6      ~5
          8        FETCH_DIM_R                                          ~7      !1, 0
          9        QM_ASSIGN                                            ~6      ~7
         10        SPACESHIP                                            ~8      ~3, ~6
         11      > RETURN                                                       ~8
   37    12*     > RETURN                                                       null

End of Dynamic Function 0

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
158.74 ms | 1936 KiB | 15 Q