Fixed regression in OS X < 10.8 establish_equivalencies()

This commit is contained in:
GRiker 2012-10-15 14:14:20 -06:00
parent 38d2389683
commit a87ca9b737

View File

@ -658,10 +658,9 @@ class CatalogBuilder(object):
ordnum, ordlen = collation_order(c) ordnum, ordlen = collation_order(c)
if isosx and platform.mac_ver()[0] < '10.8': if isosx and platform.mac_ver()[0] < '10.8':
# Hackhackhackhackhack
# icu returns bogus results with curly apostrophes, maybe others under OS X 10.6.x # icu returns bogus results with curly apostrophes, maybe others under OS X 10.6.x
# When we see the magic combo of 0/-1 for ordnum/ordlen, special case the logic # When we see the magic combo of 0/-1 for ordnum/ordlen, special case the logic
last_c = u''
if ordnum == 0 and ordlen == -1: if ordnum == 0 and ordlen == -1:
if icu_upper(c[0]) != last_c: if icu_upper(c[0]) != last_c:
last_c = icu_upper(c[0]) last_c = icu_upper(c[0])