1--TEST-- 2Bug #55355 (Abstract functions required by a trait are not correctly found when implemented in an ancestor class) 3--FILE-- 4<?php 5 6// A trait that has a abstract function 7trait ATrait { 8 function bar() { 9 $this->foo(); 10 } 11 abstract function foo(); 12} 13 14// A class on the second level in the 15// inheritance chain 16class Level2Impl { 17 function foo() {} 18} 19 20class Level1Indirect extends Level2Impl {} 21 22// A class on the first level in the 23// inheritance chain 24class Level1Direct { 25 function foo() {} 26} 27 28// Trait Uses 29 30class Direct { 31 use ATrait; 32 function foo() {} 33} 34 35class BaseL2 extends Level1Indirect { 36 use ATrait; 37} 38 39class BaseL1 extends Level1Direct { 40 use ATrait; 41} 42 43echo 'DONE'; 44?> 45--EXPECT-- 46DONE 47