xref: /PHP-8.2/Zend/tests/gh14009_002.phpt (revision c6b75f93)
1--TEST--
2GH-14009: Traits inherit prototype
3--FILE--
4<?php
5
6class P {
7    protected function common() {}
8}
9
10class A extends P {}
11
12trait T {
13    private abstract function common(int $param);
14}
15
16class B extends P {
17    use T;
18}
19
20?>
21--EXPECTF--
22Fatal error: Declaration of P::common() must be compatible with T::common(int $param) in %s on line %d
23