summaryrefslogtreecommitdiff
path: root/Zend/tests/traits/abstract_method_2.phpt
blob: 3633f9f4e1bba098a3db6bd967d7d307c7b42e40 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
--TEST--
Mutually incompatible methods from traits are fine as long as the final method is compatible
--FILE--
<?php

trait T1 {
    abstract public function test();
}
trait T2 {
    abstract public function test(): int;
}

class C {
    use T1, T2;

    public function test(): int {}
}

?>
===DONE===
--EXPECT--
===DONE===