xref: /PHP-8.3/Zend/tests/bug80126.phpt (revision 3b7c8bb9)
1--TEST--
2Bug #80126: Covariant return types failing compilation
3--FILE--
4<?php
5
6interface I {
7    public function method(): I;
8}
9
10abstract class A implements I {
11    public function method(): I { }
12}
13
14class C extends A { }
15
16class C2 extends C {
17    public function method(): C2 { }
18}
19
20?>
21===DONE===
22--EXPECT--
23===DONE===
24