[pypy-commit] pypy object-dtype: Fix Object dtype str representation

rguillebert noreply at buildbot.pypy.org
Fri Jan 16 15:31:25 CET 2015


Author: Romain Guillebert <romain.py at gmail.com>
Branch: object-dtype
Changeset: r75386:e7c050377daf
Date: 2015-01-16 15:31 +0100
http://bitbucket.org/pypy/pypy/changeset/e7c050377daf/

Log:	Fix Object dtype str representation

diff --git a/pypy/module/micronumpy/descriptor.py b/pypy/module/micronumpy/descriptor.py
--- a/pypy/module/micronumpy/descriptor.py
+++ b/pypy/module/micronumpy/descriptor.py
@@ -54,7 +54,7 @@
         self.char = char
         self.w_box_type = w_box_type
         if byteorder is None:
-            if itemtype.get_element_size() == 1:
+            if itemtype.get_element_size() == 1 or isinstance(itemtype, types.ObjectType):
                 byteorder = NPY.IGNORE
             else:
                 byteorder = NPY.NATIVE


More information about the pypy-commit mailing list