[pypy-commit] pypy default: fix annotation of malloc_nonmovable()

rlamy noreply at buildbot.pypy.org
Sun Jan 26 18:04:11 CET 2014


Author: Ronan Lamy <ronan.lamy at gmail.com>
Branch: 
Changeset: r68951:1d37bca68fa8
Date: 2014-01-26 17:03 +0000
http://bitbucket.org/pypy/pypy/changeset/1d37bca68fa8/

Log:	fix annotation of malloc_nonmovable()

diff --git a/rpython/rlib/rgc.py b/rpython/rlib/rgc.py
--- a/rpython/rlib/rgc.py
+++ b/rpython/rlib/rgc.py
@@ -114,8 +114,8 @@
 
     def compute_result_annotation(self, s_TP, s_n=None, s_zero=None):
         # basically return the same as malloc
-        from rpython.annotator.builtin import malloc
-        return malloc(s_TP, s_n, s_zero=s_zero)
+        from rpython.annotator.builtin import BUILTIN_ANALYZERS
+        return BUILTIN_ANALYZERS[lltype.malloc](s_TP, s_n, s_zero=s_zero)
 
     def specialize_call(self, hop, i_zero=None):
         # XXX assume flavor and zero to be None by now
@@ -266,7 +266,7 @@
     func._dont_inline_ = True
     func._no_release_gil_ = True
     return func
-    
+
 def no_collect(func):
     func._dont_inline_ = True
     func._gc_no_collect_ = True


More information about the pypy-commit mailing list