[pypy-commit] pypy ndarray-subtype: more hacks in compile.py

mattip noreply at buildbot.pypy.org
Mon Jul 15 18:44:42 CEST 2013


Author: Matti Picus <matti.picus at gmail.com>
Branch: ndarray-subtype
Changeset: r65405:e6eee323ec9a
Date: 2013-07-15 19:38 +0300
http://bitbucket.org/pypy/pypy/changeset/e6eee323ec9a/

Log:	more hacks in compile.py

diff --git a/pypy/module/micronumpy/compile.py b/pypy/module/micronumpy/compile.py
--- a/pypy/module/micronumpy/compile.py
+++ b/pypy/module/micronumpy/compile.py
@@ -212,6 +212,10 @@
     def call_function(self, tp, w_dtype):
         return w_dtype
 
+    def call_method(self, w_obj, s, *args, **kwargs):
+        # XXX hack
+        return getattr(w_obj, 'descr_' + s)(self, *args, **kwargs)
+
     @specialize.arg(1)
     def interp_w(self, tp, what):
         assert isinstance(what, tp)


More information about the pypy-commit mailing list