mirror of
https://github.com/php/php-src.git
synced 2026-03-24 00:02:20 +01:00
27 lines
372 B
PHP
27 lines
372 B
PHP
--TEST--
|
|
GH-17214: Relax final+private warning for trait methods with inherited final
|
|
--FILE--
|
|
<?php
|
|
|
|
trait MyTrait
|
|
{
|
|
final protected function someMethod(): void {}
|
|
}
|
|
|
|
class Test
|
|
{
|
|
use MyTrait {
|
|
someMethod as private anotherMethod;
|
|
}
|
|
|
|
public function __construct()
|
|
{
|
|
$this->anotherMethod();
|
|
}
|
|
}
|
|
|
|
?>
|
|
===DONE===
|
|
--EXPECT--
|
|
===DONE===
|