Make NumericUppercaseCollation use localized digit transforms
authorBrian Wolff <bawolff+wn@gmail.com>
Sat, 29 Oct 2016 08:29:11 +0000 (08:29 +0000)
committerBrian Wolff <bawolff+wn@gmail.com>
Sat, 29 Oct 2016 08:38:39 +0000 (08:38 +0000)
commite7464f34818f20377ca73fab72c7b3214e0f5e1c
tree0f83754dc11694418488a932fc37d31107e4d086
parenta65a3516055e5fe3e4d44ee1efd84d4754946a58
Make NumericUppercaseCollation use localized digit transforms

This will cause the numeric collation to sort localized digits
for the current content language the same as how 0-9 are.

This only deals with the localized digit numbers, commas
and other number formatting are still not handled. Weird
"numerical" unicode characters are also not handled.

I was unsure if to make a "family" of numeric collations
where you specify numeric-<lang code>, or if it should
just use $wgContLang. Given that $wgContLang effectively
never changes, and also affects all other digit handling,
I opted to just use $wgContLang.

Any wikis currently using the 'numeric' collation will
have to have updateCollation.php --force run after this
change is deployed. At the moment that includes:
bnwiki, bnwikisource and hewiki

Bug: T148873
Change-Id: I9eda52a8a9752a91134d1118546b0a80d3980ccf
includes/collation/Collation.php
includes/collation/NumericUppercaseCollation.php