magic_methods_008.phpt 387 B

12345678910111213141516171819
  1. --TEST--
  2. Testing __set implementation with wrong declaration
  3. --FILE--
  4. <?php
  5. abstract class b {
  6. abstract function __set($a, $b);
  7. }
  8. class a extends b {
  9. private function __set($a, $b) {
  10. }
  11. }
  12. ?>
  13. --EXPECTF--
  14. Warning: The magic method a::__set() must have public visibility in %s on line %d
  15. Fatal error: Access level to a::__set() must be public (as in class b) in %s on line 8