Drop Python 2 support from _cmsgpack (#376)

This commit is contained in:
Inada Naoki 2019-11-28 20:23:34 +09:00 committed by GitHub
parent b458e9a6a2
commit 891f2d8743
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 36 additions and 55 deletions

View file

@ -5,13 +5,12 @@ import struct
import warnings
if sys.version_info[0] == 2:
PY2 = True
PY2 = sys.version_info[0] == 2
if PY2:
int_types = (int, long)
def dict_iteritems(d):
return d.iteritems()
else:
PY2 = False
int_types = int
unicode = str
xrange = range