3v4l.org

run code in 300+ PHP versions simultaneously
<?php $items = array(new \stdClass(), new \stdClass()); $compare = function ($a, $b) { return $a === $b; }; $udiff = array_udiff($items, $items, $compare); var_dump($udiff); array_unshift($items, new stdClass()); $udiff = array_udiff($items, $items, $compare); var_dump($udiff); $udiff = array_udiff($items, $items, $compare); var_dump($udiff);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/5sVnr
function name:  (null)
number of ops:  43
compiled vars:  !0 = $items, !1 = $compare, !2 = $udiff
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   NEW                                              $3      'stdClass'
          1        DO_FCALL                                      0          
          2        INIT_ARRAY                                       ~5      $3
          3        NEW                                              $6      'stdClass'
          4        DO_FCALL                                      0          
          5        ADD_ARRAY_ELEMENT                                ~5      $6
          6        ASSIGN                                                   !0, ~5
    5     7        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2F5sVnr%3A5%240'
          8        ASSIGN                                                   !1, ~9
    9     9        INIT_FCALL                                               'array_udiff'
         10        SEND_VAR                                                 !0
         11        SEND_VAR                                                 !0
         12        SEND_VAR                                                 !1
         13        DO_ICALL                                         $11     
         14        ASSIGN                                                   !2, $11
   10    15        INIT_FCALL                                               'var_dump'
         16        SEND_VAR                                                 !2
         17        DO_ICALL                                                 
   12    18        INIT_FCALL                                               'array_unshift'
         19        SEND_REF                                                 !0
         20        NEW                                              $14     'stdClass'
         21        DO_FCALL                                      0          
         22        SEND_VAR                                                 $14
         23        DO_ICALL                                                 
   14    24        INIT_FCALL                                               'array_udiff'
         25        SEND_VAR                                                 !0
         26        SEND_VAR                                                 !0
         27        SEND_VAR                                                 !1
         28        DO_ICALL                                         $17     
         29        ASSIGN                                                   !2, $17
   15    30        INIT_FCALL                                               'var_dump'
         31        SEND_VAR                                                 !2
         32        DO_ICALL                                                 
   17    33        INIT_FCALL                                               'array_udiff'
         34        SEND_VAR                                                 !0
         35        SEND_VAR                                                 !0
         36        SEND_VAR                                                 !1
         37        DO_ICALL                                         $20     
         38        ASSIGN                                                   !2, $20
   18    39        INIT_FCALL                                               'var_dump'
         40        SEND_VAR                                                 !2
         41        DO_ICALL                                                 
         42      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2F5sVnr%3A5%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/5sVnr
function name:  {closure}
number of ops:  5
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    6     2        IS_IDENTICAL                                     ~2      !0, !1
          3      > RETURN                                                   ~2
    7     4*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2F5sVnr%3A5%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.06 ms | 1400 KiB | 19 Q