Commit 86ecb2c3 authored by Jason R. Coombs's avatar Jason R. Coombs

Compute PY3 directly and switch on that for clarity.

parent 3d6068d5
import sys import sys
import itertools import itertools
if sys.version_info[0] < 3: PY3 = sys.version_info >= (3,)
PY3 = False
if not PY3:
basestring = basestring basestring = basestring
import __builtin__ as builtins import __builtin__ as builtins
import ConfigParser import ConfigParser
...@@ -34,9 +34,8 @@ if sys.version_info[0] < 3: ...@@ -34,9 +34,8 @@ if sys.version_info[0] < 3:
exec("""def reraise(tp, value, tb=None): exec("""def reraise(tp, value, tb=None):
raise tp, value, tb""") raise tp, value, tb""")
else:
PY3 = True
if PY3:
basestring = str basestring = str
import builtins import builtins
import configparser as ConfigParser import configparser as ConfigParser
......
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