[Numpy-svn] r3046 - trunk/numpy/core/src

numpy-svn at scipy.org numpy-svn at scipy.org
Mon Aug 21 15:55:35 CDT 2006


Author: oliphant
Date: 2006-08-21 15:55:33 -0500 (Mon, 21 Aug 2006)
New Revision: 3046

Modified:
   trunk/numpy/core/src/arrayobject.c
Log:
Fix shape attributes of data-types with no shape

Modified: trunk/numpy/core/src/arrayobject.c
===================================================================
--- trunk/numpy/core/src/arrayobject.c	2006-08-21 20:45:00 UTC (rev 3045)
+++ trunk/numpy/core/src/arrayobject.c	2006-08-21 20:55:33 UTC (rev 3046)
@@ -10487,7 +10487,7 @@
 arraydescr_shape_get(PyArray_Descr *self)
 {
         if (self->subarray == NULL) {
-                return Py_BuildValue("(N)", PyInt_FromLong(1));
+                return PyTuple_New(0);
         }
         Py_INCREF(self->subarray->shape);
         return (PyObject *)(self->subarray->shape);



More information about the Numpy-svn mailing list