- Fixed regression in cURL extension that prevented flush of data to output
defined as a file handle. (Ilia)
+- Fixed bug #48709 (metaphone and 'wh'). (brettz9 at yahoo dot com, Felipe)
- Fixed bug #48693 (Double declaration of __lambda_func when lambda wrongly
formatted). (peter at lvp-media dot com, Felipe)
- Fixed bug #48661 (phpize is broken with non-bash shells). (Jani)
w_idx += 2;
}
break;
- /* WH becomes H,
+ /* WH becomes W,
WR becomes R
W if followed by a vowel */
case 'W':
- if (Next_Letter == 'H' ||
- Next_Letter == 'R') {
+ if (Next_Letter == 'R') {
Phonize(Next_Letter);
w_idx += 2;
- } else if (isvowel(Next_Letter)) {
+ } else if (Next_Letter == 'H' || isvowel(Next_Letter)) {
Phonize('W');
w_idx += 2;
}
--- /dev/null
+--TEST--
+Bug #48709 (metaphone and 'wh')
+--FILE--
+<?php
+
+/* Initial letter exceptions */
+$exceptions = array(
+ 'kn', // Drop first letter
+ 'gn', // ditto
+ 'pn', // ditto
+ 'ae', // ditto
+ 'wr', // ditto
+ 'x', // s
+ 'wh', // w
+ 'wa' // w
+);
+
+foreach ($exceptions as $letter) {
+ printf("%s => %s\n", $letter, metaphone($letter));
+}
+
+?>
+--EXPECT--
+kn => N
+gn => N
+pn => N
+ae => E
+wr => R
+x => S
+wh => W
+wa => W