1 parent b5d3d6c commit da5c7aaCopy full SHA for da5c7aa
2 files changed
python/phonenumbers/util.py
@@ -3,7 +3,7 @@
3
4
class UnicodeMixin(object): # pragma no cover
5
"""Define __str__ operator in terms of __unicode__ for Python 2/3"""
6
- if sys.version_info > (3, 0):
+ if sys.version_info >= (3, 0):
7
__str__ = lambda x: x.__unicode__()
8
else:
9
__str__ = lambda x: unicode(x).encode('utf-8')
python/tests/phonenumberutiltest.py
@@ -39,7 +39,7 @@
39
from .testdata import _COUNTRY_CODE_TO_REGION_CODE as TEST_CC_TO_RC
40
TEST_REGION_METADATA = PhoneMetadata.region_metadata
41
42
-if sys.version_info > (3, 0):
+if sys.version_info >= (3, 0):
43
# Python 3 has unlimited-precision int, so no 'L' suffix
44
_LS = ''
45
# Python 3 has all strings unicode, so no 'u' prefix
0 commit comments