3v4l.org

run code in 300+ PHP versions simultaneously
<?php abstract class A { abstract protected function meth(array $var); } class B extends A { public function meth($var) { return $var; } } $b = new B; echo $b->meth(33.3); // Fatal error: Declaration of B::meth($var) must be compatible with A::meth(int $var) in [...][...]on line [..]
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/CLLHD
function name:  (null)
number of ops:  8
compiled vars:  !0 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   NEW                                              $1      'B'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
   13     3        INIT_METHOD_CALL                                         !0, 'meth'
          4        SEND_VAL_EX                                              33.3
          5        DO_FCALL                                      0  $4      
          6        ECHO                                                     $4
          7      > RETURN                                                   1

Class A:
Function meth:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/CLLHD
function name:  meth
number of ops:  2
compiled vars:  !0 = $var
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
          1      > RETURN                                                   null

End of function meth

End of class A.

Class B:
Function meth:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/CLLHD
function name:  meth
number of ops:  3
compiled vars:  !0 = $var
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   RECV                                             !0      
    8     1      > RETURN                                                   !0
    9     2*     > RETURN                                                   null

End of function meth

End of class B.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
349.28 ms | 1002 KiB | 13 Q