3v4l.org

run code in 300+ PHP versions simultaneously
<?php class A{ function __isset($a){ echo "isset"; return true; } function __get($a){ return 50; } } $x = new A; var_dump($x->baz ?? 20);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/41GRh
function name:  (null)
number of ops:  10
compiled vars:  !0 = $x
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   15     0  E >   NEW                                              $1      'A'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
   16     3        INIT_FCALL                                               'var_dump'
          4        FETCH_OBJ_IS                                     ~4      !0, 'baz'
          5        COALESCE                                         ~5      ~4
          6        QM_ASSIGN                                        ~5      20
          7        SEND_VAL                                                 ~5
          8        DO_ICALL                                                 
          9      > RETURN                                                   1

Class A:
Function __isset:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/41GRh
function name:  __isset
number of ops:  4
compiled vars:  !0 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   RECV                                             !0      
    6     1        ECHO                                                     'isset'
    7     2      > RETURN                                                   <true>
    8     3*     > RETURN                                                   null

End of function __isset

Function __get:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/41GRh
function name:  __get
number of ops:  3
compiled vars:  !0 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   RECV                                             !0      
   11     1      > RETURN                                                   50
   12     2*     > RETURN                                                   null

End of function __get

End of class A.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
136.22 ms | 998 KiB | 14 Q