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