[Python-checkins] r80639 - sandbox/trunk/2to3/lib2to3/fixes/fix_sys_exc.py
benjamin.peterson
python-checkins at python.org
Thu Apr 29 23:06:09 CEST 2010
Author: benjamin.peterson
Date: Thu Apr 29 23:06:09 2010
New Revision: 80639
Log:
pass string to Number
Modified:
sandbox/trunk/2to3/lib2to3/fixes/fix_sys_exc.py
Modified: sandbox/trunk/2to3/lib2to3/fixes/fix_sys_exc.py
==============================================================================
--- sandbox/trunk/2to3/lib2to3/fixes/fix_sys_exc.py (original)
+++ sandbox/trunk/2to3/lib2to3/fixes/fix_sys_exc.py Thu Apr 29 23:06:09 2010
@@ -20,7 +20,7 @@
def transform(self, node, results):
sys_attr = results["attribute"][0]
- index = Number(self.exc_info.index(sys_attr.value))
+ index = Number(unicode(self.exc_info.index(sys_attr.value)))
call = Call(Name(u"exc_info"), prefix=sys_attr.prefix)
attr = Attr(Name(u"sys"), call)
More information about the Python-checkins
mailing list