ReflectionClass_isArray.phpt 550 B

123456789101112131415161718192021222324
  1. --TEST--
  2. public bool ReflectionParameter::isArray ( void );
  3. --CREDITS--
  4. marcosptf - <marcosptf@yahoo.com.br> - @phpsp - sao paulo - br
  5. --FILE--
  6. <?php
  7. function testReflectionIsArray($a = null, $b = 0, array $c, $d=true, array $e, $f=1.5, $g="", array $h, $i="#F989898") {}
  8. $reflection = new ReflectionFunction('testReflectionIsArray');
  9. foreach ($reflection->getParameters() as $parameter) {
  10. var_dump($parameter->isArray());
  11. }
  12. ?>
  13. --EXPECT--
  14. bool(false)
  15. bool(false)
  16. bool(true)
  17. bool(false)
  18. bool(true)
  19. bool(false)
  20. bool(false)
  21. bool(true)
  22. bool(false)