declare_003.phpt 547 B

123456789101112131415161718192021222324
  1. --TEST--
  2. Testing declare statement with several type values
  3. --INI--
  4. precision=15
  5. zend.multibyte=1
  6. --FILE--
  7. <?php
  8. declare(encoding = 1);
  9. declare(encoding = 11111111111111);
  10. declare(encoding = NULL);
  11. declare(encoding = M_PI);
  12. print 'DONE';
  13. ?>
  14. --EXPECTF--
  15. Warning: Unsupported encoding [1] in %sdeclare_003.php on line %d
  16. Warning: Unsupported encoding [11111111111111] in %sdeclare_003.php on line %d
  17. Warning: Unsupported encoding [] in %sdeclare_003.php on line %d
  18. Fatal error: Cannot use constants as encoding in %sdeclare_003.php on line %d