Kaydet (Commit) 02371e0e authored tarafından Benjamin Peterson's avatar Benjamin Peterson Kaydeden (comit) GitHub

make the glibc alias table take precedence over the X11 one (#422)

bpo-20087
üst 9f8ad3f3
This diff is collapsed.
...@@ -449,7 +449,7 @@ class NormalizeTest(unittest.TestCase): ...@@ -449,7 +449,7 @@ class NormalizeTest(unittest.TestCase):
self.check('ko_kr.euckr', 'ko_KR.eucKR') self.check('ko_kr.euckr', 'ko_KR.eucKR')
self.check('zh_cn.euc', 'zh_CN.eucCN') self.check('zh_cn.euc', 'zh_CN.eucCN')
self.check('zh_tw.euc', 'zh_TW.eucTW') self.check('zh_tw.euc', 'zh_TW.eucTW')
self.check('zh_tw.euctw', 'zh_TW.eucTW') self.check('zh_tw.euctw', 'zh_TW.EUC_TW')
def test_japanese(self): def test_japanese(self):
self.check('ja', 'ja_JP.eucJP') self.check('ja', 'ja_JP.eucJP')
...@@ -475,6 +475,9 @@ class NormalizeTest(unittest.TestCase): ...@@ -475,6 +475,9 @@ class NormalizeTest(unittest.TestCase):
self.check('japanese.sjis', 'ja_JP.SJIS') self.check('japanese.sjis', 'ja_JP.SJIS')
self.check('jp_jp', 'ja_JP.eucJP') self.check('jp_jp', 'ja_JP.eucJP')
def test_en_IN(self):
self.check('en_IN', 'en_IN.UTF-8')
class TestMiscellaneous(unittest.TestCase): class TestMiscellaneous(unittest.TestCase):
def test_getpreferredencoding(self): def test_getpreferredencoding(self):
......
...@@ -19,6 +19,8 @@ Core and Builtins ...@@ -19,6 +19,8 @@ Core and Builtins
- bpo-29695: bool(), float(), list() and tuple() no longer take keyword arguments. - bpo-29695: bool(), float(), list() and tuple() no longer take keyword arguments.
The first argument of int() can now be passes only as positional argument. The first argument of int() can now be passes only as positional argument.
- bpo-20087: Prefer glibc's list of locale aliases to the X11 ones.
- bpo-28893: Set correct __cause__ for errors about invalid awaitables - bpo-28893: Set correct __cause__ for errors about invalid awaitables
returned from __aiter__ and __anext__. returned from __aiter__ and __anext__.
......
...@@ -135,8 +135,8 @@ if __name__ == '__main__': ...@@ -135,8 +135,8 @@ if __name__ == '__main__':
args = parser.parse_args() args = parser.parse_args()
data = locale.locale_alias.copy() data = locale.locale_alias.copy()
data.update(parse_glibc_supported(args.glibc_supported))
data.update(parse(args.locale_alias)) data.update(parse(args.locale_alias))
data.update(parse_glibc_supported(args.glibc_supported))
while True: while True:
# Repeat optimization while the size is decreased. # Repeat optimization while the size is decreased.
n = len(data) n = len(data)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment