call_static_004.phpt 335 B

123456789101112131415161718192021222324
  1. --TEST--
  2. Invalid method name in dynamic static call
  3. --FILE--
  4. <?php
  5. class foo {
  6. static function __callstatic($a, $b) {
  7. var_dump($a);
  8. }
  9. }
  10. foo::AaA();
  11. $a = 1;
  12. foo::$a();
  13. ?>
  14. --EXPECTF--
  15. string(3) "AaA"
  16. Fatal error: Uncaught Error: Method name must be a string in %s:%d
  17. Stack trace:
  18. #0 {main}
  19. thrown in %s on line %d