3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = json_decode('{"foo": "bar"}', true); $baz = $array['baz'] ?: null; var_dump($baz);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/O968T
function name:  (null)
number of ops:  13
compiled vars:  !0 = $array, !1 = $baz
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'json_decode'
          1        SEND_VAL                                                 '%7B%22foo%22%3A+%22bar%22%7D'
          2        SEND_VAL                                                 <true>
          3        DO_ICALL                                         $2      
          4        ASSIGN                                                   !0, $2
    4     5        FETCH_DIM_R                                      ~4      !0, 'baz'
          6        JMP_SET                                          ~5      ~4, ->8
          7        QM_ASSIGN                                        ~5      null
          8        ASSIGN                                                   !1, ~5
    5     9        INIT_FCALL                                               'var_dump'
         10        SEND_VAR                                                 !1
         11        DO_ICALL                                                 
         12      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
138.59 ms | 1436 KiB | 15 Q