3v4l.org

run code in 500+ PHP versions simultaneously
<?php $data='{"multicast_id":7917175795873320166,"success":6,"failure":0,"canonical_ids":4, "results":[ {"registration_id":"3","message_id":"m1"}, {"message_id":"m1"}, {"message_id":"m1"}, {"registration_id":"3","message_id":"m1"}, {"registration_id":"3","message_id":"m1"}, {"registration_id":"3","message_id":"m1"}]}'; $newData=json_decode($data, true); $filteredResults = array_filter($newData['results'], function($item) { return isset($item['registration_id']); }); print_r(array_keys($filteredResults));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/e8doL
function name:  (null)
number of ops:  20
compiled vars:  !0 = $data, !1 = $newData, !2 = $filteredResults
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                       !0, '%7B%22multicast_id%22%3A7917175795873320166%2C%22success%22%3A6%2C%22failure%22%3A0%2C%22canonical_ids%22%3A4%2C%0A%0A%22results%22%3A%5B%0A%0A%7B%22registration_id%22%3A%223%22%2C%22message_id%22%3A%22m1%22%7D%2C%0A%7B%22message_id%22%3A%22m1%22%7D%2C%0A%7B%22message_id%22%3A%22m1%22%7D%2C%0A%7B%22registration_id%22%3A%223%22%2C%22message_id%22%3A%22m1%22%7D%2C%0A%0A%7B%22registration_id%22%3A%223%22%2C%22message_id%22%3A%22m1%22%7D%2C%0A%0A%7B%22registration_id%22%3A%223%22%2C%22message_id%22%3A%22m1%22%7D%5D%7D'
   15     1        INIT_FCALL                                                   'json_decode'
          2        SEND_VAR                                                     !0
          3        SEND_VAL                                                     <true>
          4        DO_ICALL                                             $4      
          5        ASSIGN                                                       !1, $4
   17     6        INIT_FCALL                                                   'array_filter'
          7        FETCH_DIM_R                                          ~6      !1, 'results'
          8        SEND_VAL                                                     ~6
          9        DECLARE_LAMBDA_FUNCTION                              ~7      [0]
   19    10        SEND_VAL                                                     ~7
   17    11        DO_ICALL                                             $8      
         12        ASSIGN                                                       !2, $8
   21    13        INIT_FCALL                                                   'print_r'
         14        INIT_FCALL                                                   'array_keys'
         15        SEND_VAR                                                     !2
         16        DO_ICALL                                             $10     
         17        SEND_VAR                                                     $10
         18        DO_ICALL                                                     
         19      > 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/e8doL
function name:  {closure:/in/e8doL:17}
number of ops:  4
compiled vars:  !0 = $item
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   17     0  E >   RECV                                                 !0      
   18     1        ISSET_ISEMPTY_DIM_OBJ                             0  ~1      !0, 'registration_id'
          2      > RETURN                                                       ~1
   19     3*     > RETURN                                                       null

End of Dynamic Function 0

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
210.87 ms | 2849 KiB | 17 Q