[Numpy-svn] r5046 - trunk/numpy/f2py

numpy-svn@scip... numpy-svn@scip...
Fri Apr 18 14:59:46 CDT 2008


Author: pearu
Date: 2008-04-18 14:59:42 -0500 (Fri, 18 Apr 2008)
New Revision: 5046

Modified:
   trunk/numpy/f2py/crackfortran.py
Log:
Fix bug in parsing initexpr in 'INTEGER, PARAMETER :: ny = nx + 2'

Modified: trunk/numpy/f2py/crackfortran.py
===================================================================
--- trunk/numpy/f2py/crackfortran.py	2008-04-18 16:16:05 UTC (rev 5045)
+++ trunk/numpy/f2py/crackfortran.py	2008-04-18 19:59:42 UTC (rev 5046)
@@ -1202,7 +1202,7 @@
     expr2=expr[0]
     for i in range(1,len(expr)-1):
         if expr[i]==' ' and \
-           ((expr[i+1] in "()[]{}= ") or (expr[i-1] in "()[]{}= ")): continue
+           ((expr[i+1] in "()[]{}=+-/* ") or (expr[i-1] in "()[]{}=+-/* ")): continue
         expr2=expr2+expr[i]
     expr2=expr2+expr[-1]
     return expr2



More information about the Numpy-svn mailing list