3v4l.org

run code in 300+ PHP versions simultaneously
<?php $json=<<<EOF [ { "id":23, "uid":"0090000219", "cid":"0090000013", "extension":"201", "secret":"Myojyo42_f", "leader":true, "simultaneous":false, "confbridge_id":17, "created_at":"2015-09-02 12:49:12", "updated_at":"2015-09-02 12:49:12" }, { "id":24, "uid":"0090000221", "cid":"0090000013", "extension":"203", "secret":"Myojyo42_f", "leader":false, "simultaneous":false, "confbridge_id":17, "created_at":"2015-09-02 12:49:12", "updated_at":"2015-09-02 12:49:12" }, { "id":25, "uid":"0090000223", "cid":"0090000013", "extension":"205", "secret":"Myojyo42_f", "leader":false, "simultaneous":false, "confbridge_id":17, "created_at":"2015-09-10 10:16:24", "updated_at":"2015-09-10 10:16:24" } ] EOF; echo count (array_filter(function($a){ return $a->leader?1:0;}, json_decode($json)));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/5ehTb
function name:  (null)
number of ops:  12
compiled vars:  !0 = $json
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '%5B%0A%7B%0A%22id%22%3A23%2C%0A%22uid%22%3A%220090000219%22%2C%0A%22cid%22%3A%220090000013%22%2C%0A%22extension%22%3A%22201%22%2C%0A%22secret%22%3A%22Myojyo42_f%22%2C%0A%22leader%22%3Atrue%2C%0A%22simultaneous%22%3Afalse%2C%0A%22confbridge_id%22%3A17%2C%0A%22created_at%22%3A%222015-09-02+12%3A49%3A12%22%2C%0A%22updated_at%22%3A%222015-09-02+12%3A49%3A12%22%0A%7D%2C%0A%7B%0A%22id%22%3A24%2C%0A%22uid%22%3A%220090000221%22%2C%0A%22cid%22%3A%220090000013%22%2C%0A%22extension%22%3A%22203%22%2C%0A%22secret%22%3A%22Myojyo42_f%22%2C%0A%22leader%22%3Afalse%2C%0A%22simultaneous%22%3Afalse%2C%0A%22confbridge_id%22%3A17%2C%0A%22created_at%22%3A%222015-09-02+12%3A49%3A12%22%2C%0A%22updated_at%22%3A%222015-09-02+12%3A49%3A12%22%0A%7D%2C%0A%7B%0A%22id%22%3A25%2C%0A%22uid%22%3A%220090000223%22%2C%0A%22cid%22%3A%220090000013%22%2C%0A%22extension%22%3A%22205%22%2C%0A%22secret%22%3A%22Myojyo42_f%22%2C%0A%22leader%22%3Afalse%2C%0A%22simultaneous%22%3Afalse%2C%0A%22confbridge_id%22%3A17%2C%0A%22created_at%22%3A%222015-09-10+10%3A16%3A24%22%2C%0A%22updated_at%22%3A%222015-09-10+10%3A16%3A24%22%0A%7D%0A%5D'
   45     1        INIT_FCALL                                               'array_filter'
          2        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2F5ehTb%3A45%240'
          3        SEND_VAL                                                 ~2
          4        INIT_FCALL                                               'json_decode'
          5        SEND_VAR                                                 !0
          6        DO_ICALL                                         $3      
          7        SEND_VAR                                                 $3
          8        DO_ICALL                                         $4      
          9        COUNT                                            ~5      $4
         10        ECHO                                                     ~5
         11      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2F5ehTb%3A45%240:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 3, Position 2 = 5
Branch analysis from position: 3
1 jumps found. (Code = 42) Position 1 = 6
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 5
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/5ehTb
function name:  {closure}
number of ops:  8
compiled vars:  !0 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
          0  E >   RECV                                             !0      
          1        FETCH_OBJ_R                                      ~1      !0, 'leader'
          2      > JMPZ                                                     ~1, ->5
          3    >   QM_ASSIGN                                        ~2      1
          4      > JMP                                                      ->6
          5    >   QM_ASSIGN                                        ~2      0
          6    > > RETURN                                                   ~2
          7*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2F5ehTb%3A45%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
174.05 ms | 1396 KiB | 17 Q