3v4l.org

run code in 300+ PHP versions simultaneously
<?php declare(strict=1); class Test { } class A { public function abc(): Test { return null; } } $b = new A; print_r([ $b->abc() ]);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/OSW0E
function name:  (null)
number of ops:  10
compiled vars:  !0 = $b
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                                               'print_r'
   17     4        INIT_METHOD_CALL                                         !0, 'abc'
          5        DO_FCALL                                      0  $4      
          6        INIT_ARRAY                                       ~5      $4
          7        SEND_VAL                                                 ~5
          8        DO_ICALL                                                 
   18     9      > RETURN                                                   1

Class Test: [no user functions]
Class A:
Function abc:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/OSW0E
function name:  abc
number of ops:  4
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   VERIFY_RETURN_TYPE                               ~0      null
          1      > RETURN                                                   ~0
   11     2*       VERIFY_RETURN_TYPE                                       
          3*     > RETURN                                                   null

End of function abc

End of class A.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
166.07 ms | 1394 KiB | 15 Q