bug47593.phpt 473 B

12345678910111213141516171819202122232425262728293031323334
  1. --TEST--
  2. Bug #47593 (interface_exists() returns false when using absolute namespace path)
  3. --FILE--
  4. <?php
  5. namespace test;
  6. const TEST = 11;
  7. class foo {
  8. public function xyz() {
  9. }
  10. }
  11. interface baz {
  12. }
  13. function bar() {
  14. }
  15. var_dump(interface_exists('\test\baz'));
  16. var_dump(function_exists('\test\bar'));
  17. var_dump(constant('\test\TEST'));
  18. var_dump(defined('\test\TEST'));
  19. var_dump(defined('TEST'));
  20. ?>
  21. --EXPECT--
  22. bool(true)
  23. bool(true)
  24. int(11)
  25. bool(true)
  26. bool(false)