1--TEST-- 2MessageFormatter::format() invalid type for key not in pattern 3--SKIPIF-- 4<?php 5if (!extension_loaded('intl')) 6 die('skip intl extension not enabled'); 7if (version_compare(INTL_ICU_VERSION, '4.8') < 0) 8 die('skip for ICU 4.8+'); 9--FILE-- 10<?php 11ini_set("intl.error_level", E_WARNING); 12 13$fmt = <<<EOD 14{foo} 15EOD; 16 17$mf = new MessageFormatter('en_US', $fmt); 18var_dump($mf->format(array("foo" => 'bar', 7 => fopen('php://memory', 'r+')))); 19--EXPECTF-- 20Warning: MessageFormatter::format(): No strategy to convert the value given for the argument with key '7' is available in %s on line %d 21bool(false) 22