[pypy-commit] pypy mro-reorder-numpypy-str: remove W_StringBox delegation
mattip
noreply at buildbot.pypy.org
Thu Aug 1 21:55:35 CEST 2013
Author: Matti Picus <matti.picus at gmail.com>
Branch: mro-reorder-numpypy-str
Changeset: r65885:eb6ab033bef4
Date: 2013-08-01 22:03 +0300
http://bitbucket.org/pypy/pypy/changeset/eb6ab033bef4/
Log: remove W_StringBox delegation
diff --git a/pypy/module/micronumpy/stdobjspace.py b/pypy/module/micronumpy/stdobjspace.py
deleted file mode 100644
--- a/pypy/module/micronumpy/stdobjspace.py
+++ /dev/null
@@ -1,11 +0,0 @@
-
-from pypy.objspace.std import stringobject
-from pypy.module.micronumpy import interp_boxes
-
-def delegate_stringbox2stringobj(space, w_box):
- return space.wrap(w_box.dtype.itemtype.to_str(w_box))
-
-def register_delegates(typeorder):
- typeorder[interp_boxes.W_StringBox] = [
- (stringobject.W_StringObject, delegate_stringbox2stringobj),
- ]
diff --git a/pypy/module/micronumpy/test/test_dtypes.py b/pypy/module/micronumpy/test/test_dtypes.py
--- a/pypy/module/micronumpy/test/test_dtypes.py
+++ b/pypy/module/micronumpy/test/test_dtypes.py
@@ -740,7 +740,7 @@
class AppTestStrUnicodeDtypes(BaseNumpyAppTest):
def test_str_unicode(self):
- py.test.skip('numpypy differs from numpy')
+ skip('numpypy differs from numpy')
from numpypy import str_, unicode_, character, flexible, generic
assert str_.mro() == [str_, str, basestring, character, flexible, generic, object]
diff --git a/pypy/objspace/std/model.py b/pypy/objspace/std/model.py
--- a/pypy/objspace/std/model.py
+++ b/pypy/objspace/std/model.py
@@ -133,10 +133,6 @@
# when trying to dispatch multimethods.
# XXX build these lists a bit more automatically later
- if config.objspace.usemodules.micronumpy:
- from pypy.module.micronumpy.stdobjspace import register_delegates
- register_delegates(self.typeorder)
-
self.typeorder[boolobject.W_BoolObject] += [
(intobject.W_IntObject, boolobject.delegate_Bool2IntObject),
(floatobject.W_FloatObject, floatobject.delegate_Bool2Float),
More information about the pypy-commit
mailing list