summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTarek Ziadé <ziade.tarek@gmail.com>2009-05-12 07:06:42 (GMT)
committerTarek Ziadé <ziade.tarek@gmail.com>2009-05-12 07:06:42 (GMT)
commitda31a3f0c2303796ece492e1bdcd4fe2e4c21953 (patch)
treef933aa44ff278d3f77b804cbcc679c7872272944
parent3261fa5a6ba6afd04cf508ed9a59482021c9ae43 (diff)
downloadcpython-da31a3f0c2303796ece492e1bdcd4fe2e4c21953.zip
cpython-da31a3f0c2303796ece492e1bdcd4fe2e4c21953.tar.gz
cpython-da31a3f0c2303796ece492e1bdcd4fe2e4c21953.tar.bz2
Merged revisions 72577 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk ........ r72577 | tarek.ziade | 2009-05-12 09:01:29 +0200 (Tue, 12 May 2009) | 1 line removing the assert statement so the code works when Python is run with -O ........
-rw-r--r--Lib/distutils/command/install_lib.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/Lib/distutils/command/install_lib.py b/Lib/distutils/command/install_lib.py
index 022efa4..85fb3ac 100644
--- a/Lib/distutils/command/install_lib.py
+++ b/Lib/distutils/command/install_lib.py
@@ -77,7 +77,8 @@ class install_lib(Command):
if not isinstance(self.optimize, int):
try:
self.optimize = int(self.optimize)
- assert self.optimize in (0, 1, 2)
+ if self.optimize not in (0, 1, 2):
+ raise AssertionError
except (ValueError, AssertionError):
raise DistutilsOptionError("optimize must be 0, 1, or 2")