3v4l.org

run code in 300+ PHP versions simultaneously
<?php $obj = new stdClass; $obj->{123} = '456'; var_dump($obj); if (property_exists($obj,123)) { echo 'Property 123 exists',"\n"; } if (isset($obj->{123})) { echo "Property value: {$obj->{123}}\n"; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 13, Position 2 = 15
Branch analysis from position: 13
2 jumps found. (Code = 43) Position 1 = 17, Position 2 = 22
Branch analysis from position: 17
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 22
Branch analysis from position: 15
filename:       /in/sbkZN
function name:  (null)
number of ops:  23
compiled vars:  !0 = $obj
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   NEW                                              $1      'stdClass'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
    3     3        ASSIGN_OBJ                                               !0, '123'
          4        OP_DATA                                                  '456'
    4     5        INIT_FCALL                                               'var_dump'
          6        SEND_VAR                                                 !0
          7        DO_ICALL                                                 
    6     8        INIT_FCALL                                               'property_exists'
          9        SEND_VAR                                                 !0
         10        SEND_VAL                                                 123
         11        DO_ICALL                                         $6      
         12      > JMPZ                                                     $6, ->15
    7    13    >   ECHO                                                     'Property+123+exists'
         14        ECHO                                                     '%0A'
    9    15    >   ISSET_ISEMPTY_PROP_OBJ                                   !0, '123'
         16      > JMPZ                                                     ~7, ->22
   10    17    >   ROPE_INIT                                     3  ~10     'Property+value%3A+'
         18        FETCH_OBJ_R                                      ~8      !0, '123'
         19        ROPE_ADD                                      1  ~10     ~10, ~8
         20        ROPE_END                                      2  ~9      ~10, '%0A'
         21        ECHO                                                     ~9
   11    22    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
156.44 ms | 1387 KiB | 17 Q