Merge "LanguageNameSearch: do not mix different scripts in same buckets"

This commit is contained in:
jenkins-bot authored and Gerrit Code Review committed 2016-08-09 04:02:41 +00:00
commit 18ea003604
2 files changed
+13691 -13829

No files matched your search

+9 -1
View File
@@ -46,7 +46,15 @@ class LanguageNameSearch {
} }
public static function getIndex( $name ) { public static function getIndex( $name ) {
return self::getCodepoint( $name ) % 1000; $codepoint = self::getCodepoint( $name );
if ( $codepoint < 4000 ) {
// For latin etc. we need smaller buckets for speed
return $codepoint;
} else {
// Try to group names of same script together
return $codepoint - ( $codepoint % 1000 );
}
} }
/** /**
+13682 -13828
View File
File diff suppressed because it is too large. Load diff