ctor_in_interface_03.phpt 384 B

1234567891011121314151617181920212223
  1. --TEST--
  2. ZE2 A class constructor must keep the signature of base class interfaces
  3. --FILE--
  4. <?php
  5. interface constr
  6. {
  7. function __construct();
  8. }
  9. abstract class implem implements constr
  10. {
  11. }
  12. class derived extends implem
  13. {
  14. function __construct($a)
  15. {
  16. }
  17. }
  18. ?>
  19. --EXPECTF--
  20. Fatal error: Declaration of derived::__construct() must be compatible with constr::__construct() in %s on line %d