bug74484_MessageFormatter.phpt 478 B

12345678910111213141516171819202122232425262728
  1. --TEST--
  2. Bug #74484 MessageFormatter::formatMessage memory corruption with 11+ named placeholder
  3. --EXTENSIONS--
  4. intl
  5. --FILE--
  6. <?php
  7. $text = "{a} {b} {c} {d} {e} {f} {g} {h} {i} {j} {k} {l}";
  8. $vars = array(
  9. 'a' => 1,
  10. 'b' => 2,
  11. 'c' => 3,
  12. 'd' => 4,
  13. 'e' => 5,
  14. 'f' => 6,
  15. 'g' => 7,
  16. 'h' => 8,
  17. 'i' => 9,
  18. 'j' => 10,
  19. 'k' => 11,
  20. 'l' => 12
  21. );
  22. var_dump(MessageFormatter::formatMessage('en_US', $text, $vars));
  23. ?>
  24. --EXPECT--
  25. string(26) "1 2 3 4 5 6 7 8 9 10 11 12"