summaryrefslogtreecommitdiff
path: root/Zend/tests/traits/error_001.phpt
blob: 307e5c128ad34e614491c43bc21038aeb0c821f6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
--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