Skip to content

Commit 67addfe

Browse files
committed
Implement Mark Favas's suggestion. There's a clear bug in _group():
its first return statement returns a single value while its caller always expects it to return a tuple of two items. Fix this by returning (s, 0) instead. This won't make the locale test on Irix succeed, but now it will fail because of a bug in the platform's en_US locale rather than because of a bug in the locale module.
1 parent 1fcd438 commit 67addfe

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Lib/locale.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ def strxfrm(s):
9393
def _group(s):
9494
conv=localeconv()
9595
grouping=conv['grouping']
96-
if not grouping:return s
96+
if not grouping:return (s, 0)
9797
result=""
9898
seps = 0
9999
spaces = ""

0 commit comments

Comments
 (0)