[Numpy-svn] r3425 - in trunk/numpy: f2py lib

numpy-svn at scipy.org numpy-svn at scipy.org
Thu Nov 2 10:07:54 CST 2006


Author: oliphant
Date: 2006-11-02 10:07:43 -0600 (Thu, 02 Nov 2006)
New Revision: 3425

Modified:
   trunk/numpy/f2py/crackfortran.py
   trunk/numpy/lib/shape_base.py
Log:
Apply #368

Modified: trunk/numpy/f2py/crackfortran.py
===================================================================
--- trunk/numpy/f2py/crackfortran.py	2006-11-02 04:35:04 UTC (rev 3424)
+++ trunk/numpy/f2py/crackfortran.py	2006-11-02 16:07:43 UTC (rev 3425)
@@ -1647,13 +1647,13 @@
             if args is not None and b['name'] not in args:
                 continue
             else:
-                as=b['args']
+                as_=b['args']
             if b['name'] in skipfuncs:
                 continue
             if onlyfuncs and b['name'] not in onlyfuncs:
                 continue
-        else: as=args
-        b=postcrack(b,as,tab=tab+'\t')
+        else: as_=args
+        b=postcrack(b,as_,tab=tab+'\t')
         if b['block']=='interface' and not b['body']:
             if not b.has_key('f2pyenhancements'):
                 continue

Modified: trunk/numpy/lib/shape_base.py
===================================================================
--- trunk/numpy/lib/shape_base.py	2006-11-02 04:35:04 UTC (rev 3424)
+++ trunk/numpy/lib/shape_base.py	2006-11-02 16:07:43 UTC (rev 3425)
@@ -553,20 +553,20 @@
     ndb, nda = b.ndim, a.ndim
     if (nda == 0 or ndb == 0):
         return _nx.multiply(a,b)
-    as = a.shape
+    as_ = a.shape
     bs = b.shape
     if not a.flags.contiguous:
-        a = reshape(a, as)
+        a = reshape(a, as_)
     if not b.flags.contiguous:
         b = reshape(b, bs)
     nd = ndb
     if (ndb != nda):
         if (ndb > nda):
-            as = (1,)*(ndb-nda) + as
+            as_ = (1,)*(ndb-nda) + as_
         else:
             bs = (1,)*(nda-ndb) + bs
             nd = nda        
-    result = outer(a,b).reshape(as+bs)
+    result = outer(a,b).reshape(as_+bs)
     axis = nd-1
     for k in xrange(nd):
         result = concatenate(result, axis=axis)



More information about the Numpy-svn mailing list