1--TEST-- 2IntlRuleBasedBreakIterator::__construct: basic test 3--SKIPIF-- 4<?php 5if (!extension_loaded('intl')) 6 die('skip intl extension not enabled'); 7--FILE-- 8<?php 9ini_set("intl.default_locale", "pt_PT"); 10 11$rules = <<<RULES 12\$LN = [[:letter:] [:number:]]; 13\$S = [.;,:]; 14 15!!forward; 16\$LN+ {1}; 17\$S+ {42}; 18!!reverse; 19\$LN+ {1}; 20\$S+ {42}; 21!!safe_forward; 22!!safe_reverse; 23RULES; 24$rbbi = new IntlRuleBasedBreakIterator($rules); 25var_dump(get_class($rbbi)); 26 27try { 28 $obj = new IntlRuleBasedBreakIterator('[\p{Letter}\uFFFD]+;[:number:]+', 'aoeu'); 29} catch (IntlException $e) { 30 echo $e->getMessage(), "\n"; 31} 32 33?> 34--EXPECT-- 35string(26) "IntlRuleBasedBreakIterator" 36IntlRuleBasedBreakIterator::__construct(): unable to create instance from compiled rules 37