php-src/Zend/tests/traits/bug60217a.phpt
Stefan Marr 7334dfd7eb Fixed Bug #60217 (Requiring the same method from different traits)
- also added test to check for inconsistent abstract method definitions, they need to be compatible
2011-11-05 01:46:40 +00:00

27 lines
337 B
PHP

--TEST--
Bug #60217 (Requiring the same method from different traits.)
--FILE--
<?php
trait T1 {
public abstract function foo();
}
trait T2 {
public abstract function foo();
}
class C {
use T1, T2;
public function foo() {
echo "C::foo() works.\n";
}
}
$o = new C;
$o->foo();
--EXPECTF--
C::foo() works.