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

numpy-svn@scip... numpy-svn@scip...
Tue Apr 17 05:34:59 CDT 2007


Author: pearu
Date: 2007-04-17 05:34:54 -0500 (Tue, 17 Apr 2007)
New Revision: 3718

Modified:
   trunk/numpy/f2py/capi_maps.py
Log:
f2py: support for assumed shape arrays of fortran callback functions (will not work with python callback functions, for instance).

Modified: trunk/numpy/f2py/capi_maps.py
===================================================================
--- trunk/numpy/f2py/capi_maps.py	2007-04-17 04:54:49 UTC (rev 3717)
+++ trunk/numpy/f2py/capi_maps.py	2007-04-17 10:34:54 UTC (rev 3718)
@@ -307,6 +307,10 @@
             i=i+1
             if d not in ['*',':','(*)','(:)']:
                 ret['cbsetdims']='%s#varname#_Dims[%d]=%s,'%(ret['cbsetdims'],i,d)
+            elif isintent_in(var):
+                outmess('getarrdims:warning: assumed shape array, using 0 instead of %r\n' \
+                        % (d))
+                ret['cbsetdims']='%s#varname#_Dims[%d]=%s,'%(ret['cbsetdims'],i,0)
             elif verbose :
                 errmess('getarrdims: If in call-back function: array argument %s must have bounded dimensions: got %s\n'%(`a`,`d`))
         if ret['cbsetdims']: ret['cbsetdims']=ret['cbsetdims'][:-1]



More information about the Numpy-svn mailing list