3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php trait TA { function foo() {} } trait TB { function foo() {} } class C { use TA, TB { TB::foo as bar; } }
based on OEgZF
Output for 7.0.0 - 7.2.0
Fatal error: Trait method foo has not been applied, because there are collisions with other trait methods on C in /in/rAdQE on line 11
Process exited with code 255.
Output for 5.4.11 - 5.6.28
Fatal error: Trait method foo has not been applied, because there are collisions with other trait methods on C in /in/rAdQE on line 15
Process exited with code 255.
Output for 5.3.21 - 5.3.29
Parse error: syntax error, unexpected T_STRING in /in/rAdQE on line 3
Process exited with code 255.