1
0
mirror of https://github.com/php/php-src.git synced 2026-04-10 01:23:53 +02:00
Files
archived-php-src/Zend/tests/traits/error_001.phpt
Felipe Pena 6e8db0b35a - New tests
2010-05-04 19:06:13 +00:00

29 lines
357 B
PHP

--TEST--
Trying to use instanceof for a method twice
--FILE--
<?php
trait foo {
public function foo() {
return 1;
}
}
trait foo2 {
public function foo() {
return 2;
}
}
class A extends foo {
use foo {
foo2::foo insteadof foo;
foo2::foo insteadof foo;
}
}
?>
--EXPECTF--
Fatal error: Class A cannot extend from trait foo in %s on line %d