[Scipy-svn] r7117 - trunk/scipy/weave

scipy-svn at scipy.org scipy-svn at scipy.org
Mon Jan 31 17:39:02 EST 2011


Author: warren.weckesser
Date: 2011-01-31 16:39:01 -0600 (Mon, 31 Jan 2011)
New Revision: 7117

Modified:
   trunk/scipy/weave/blitz_tools.py
   trunk/scipy/weave/bytecodecompiler.py
Log:
PY3: weave: No need to support old-style string exceptions, since scipy requires at least python 2.4.

Modified: trunk/scipy/weave/blitz_tools.py
===================================================================
--- trunk/scipy/weave/blitz_tools.py	2011-01-31 21:52:58 UTC (rev 7116)
+++ trunk/scipy/weave/blitz_tools.py	2011-01-31 22:39:01 UTC (rev 7117)
@@ -32,10 +32,7 @@
     #    of time.  It also can cause core-dumps if the sizes of the inputs
     #    aren't compatible.
     if check_size and not size_check.check_expr(expr,local_dict,global_dict):
-        if sys.version_info < (2, 6):
-            raise "inputs failed to pass size check."
-        else:
-            raise ValueError("inputs failed to pass size check.")
+        raise ValueError("inputs failed to pass size check.")
 
     # 2. try local cache
     try:

Modified: trunk/scipy/weave/bytecodecompiler.py
===================================================================
--- trunk/scipy/weave/bytecodecompiler.py	2011-01-31 21:52:58 UTC (rev 7116)
+++ trunk/scipy/weave/bytecodecompiler.py	2011-01-31 22:39:01 UTC (rev 7117)
@@ -238,10 +238,7 @@
         elif goto is None:
             return next # Normal
         else:
-            if sys.version_info < (2, 6):
-                raise "Executing code failed."
-            else:
-                raise ValueError("Executing code failed.")
+            raise ValueError("Executing code failed.")
 
     symbols = { 0: 'less', 1: 'lesseq', 2: 'equal', 3: 'notequal',
                 4: 'greater', 5: 'greatereq', 6: 'in', 7: 'not in',




More information about the Scipy-svn mailing list