[Numpy-svn] r5322 - trunk/numpy/core

numpy-svn@scip... numpy-svn@scip...
Sat Jun 28 21:28:49 CDT 2008


Author: charris
Date: 2008-06-28 21:28:43 -0500 (Sat, 28 Jun 2008)
New Revision: 5322

Modified:
   trunk/numpy/core/records.py
Log:
Fix ticket #390.


Modified: trunk/numpy/core/records.py
===================================================================
--- trunk/numpy/core/records.py	2008-06-28 21:02:25 UTC (rev 5321)
+++ trunk/numpy/core/records.py	2008-06-29 02:28:43 UTC (rev 5322)
@@ -309,6 +309,10 @@
             return obj.view(ndarray)
         return obj
 
+    def __repr__(self) :
+        ret = ndarray.__repr__(self)
+        return ret.replace("recarray", "rec.array", 1)
+
     def field(self, attr, val=None):
         if isinstance(attr, int):
             names = ndarray.__getattribute__(self,'dtype').names



More information about the Numpy-svn mailing list