Author: Alex Gaynor <[email protected]>
Branch: 
Changeset: r63279:77328bd10f85
Date: 2013-04-12 07:26 -0700
http://bitbucket.org/pypy/pypy/changeset/77328bd10f85/

Log:    remove some if 0:s

diff --git a/pypy/interpreter/pyopcode.py b/pypy/interpreter/pyopcode.py
--- a/pypy/interpreter/pyopcode.py
+++ b/pypy/interpreter/pyopcode.py
@@ -255,19 +255,7 @@
                                              "code=%d, name=%s" %
                                              (self.last_instr, opcode,
                                               methodname))
-                try:
-                    res = meth(oparg, next_instr)
-                except Exception:
-                    if 0:
-                        import dis, sys
-                        print "*** %s at offset %d (%s)" % (sys.exc_info()[0],
-                                                            self.last_instr,
-                                                            methodname)
-                        try:
-                            dis.dis(co_code)
-                        except:
-                            pass
-                    raise
+                res = meth(oparg, next_instr)
                 if res is not None:
                     next_instr = res
 
diff --git a/rpython/rtyper/extfunc.py b/rpython/rtyper/extfunc.py
--- a/rpython/rtyper/extfunc.py
+++ b/rpython/rtyper/extfunc.py
@@ -1,7 +1,6 @@
 from rpython.rtyper import extregistry
 from rpython.rtyper.extregistry import ExtRegistryEntry
 from rpython.rtyper.lltypesystem.lltype import typeOf
-from rpython.flowspace.model import Constant
 from rpython.annotator import model as annmodel
 from rpython.annotator.signature import annotation
 
@@ -29,14 +28,9 @@
             register_external(funcs[0], *val.def_args, **val.def_kwds)
             return
         return val
-    except (SystemExit, MemoryError, KeyboardInterrupt), e:
+    except (SystemExit, MemoryError, KeyboardInterrupt):
         raise
     except:
-        if 0:
-            import traceback
-            print >> sys.stderr, 'WARNING: cannot register', func_or_list, ':'
-            traceback.print_exc()
-            import pdb; pdb.set_trace()
         exc, exc_inst, tb = sys.exc_info()
         for func in funcs:
             # if the function has already been registered and we got
@@ -250,7 +244,7 @@
             signature_args = args
 
         signature_result = annotation(result, None)
-        name=export_name
+        name = export_name
         if llimpl:
             lltypeimpl = staticmethod(llimpl)
         if ooimpl:
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to