Annotation of embedaddon/php/Zend/tests/traits/bugs/interfaces.phpt, revision 1.1
1.1 ! misho 1: --TEST--
! 2: Make sure trait does not implement an interface.
! 3: --FILE--
! 4: <?php
! 5: error_reporting(E_ALL);
! 6:
! 7: interface MyInterface {
! 8: public function a();
! 9: }
! 10:
! 11: trait THello implements MyInterface {
! 12: public function a() {
! 13: echo 'A';
! 14: }
! 15: }
! 16:
! 17: ?>
! 18: --EXPECTF--
! 19: Fatal error: Cannot use 'MyInterface' as interface on 'THello' since it is a Trait in %s on line %d
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>