mirror of
https://github.com/php/php-src.git
synced 2024-10-17 14:32:37 +00:00
b501570ab0
#Getting accustomed to the infrastructure. #Any comments are welcome, especially with regard to syntax and keywords.
31 lines
439 B
PHP
31 lines
439 B
PHP
--TEST--
|
|
Overridding Conflicting Methods should not result in a notice/warning about collisions
|
|
--FILE--
|
|
<?php
|
|
error_reporting(E_ALL);
|
|
|
|
trait THello1 {
|
|
public function hello() {
|
|
echo 'Hello';
|
|
}
|
|
}
|
|
|
|
trait THello2 {
|
|
public function hello() {
|
|
echo 'Hello';
|
|
}
|
|
}
|
|
|
|
class TraitsTest {
|
|
use THello1;
|
|
use THello2;
|
|
public function hello() {
|
|
echo 'Hello';
|
|
}
|
|
}
|
|
|
|
$test = new TraitsTest();
|
|
$test->hello();
|
|
?>
|
|
--EXPECTF--
|
|
Hello
|