[pypy-svn] r49006 - pypy/branch/remove-extcompiler-rctypes/pypy/translator/c

cfbolz at codespeak.net cfbolz at codespeak.net
Fri Nov 23 20:28:46 CET 2007


Author: cfbolz
Date: Fri Nov 23 20:28:45 2007
New Revision: 49006

Modified:
   pypy/branch/remove-extcompiler-rctypes/pypy/translator/c/pyobj.py
Log:
use_true_methods is never true any more. kill it.


Modified: pypy/branch/remove-extcompiler-rctypes/pypy/translator/c/pyobj.py
==============================================================================
--- pypy/branch/remove-extcompiler-rctypes/pypy/translator/c/pyobj.py	(original)
+++ pypy/branch/remove-extcompiler-rctypes/pypy/translator/c/pyobj.py	Fri Nov 23 20:28:45 2007
@@ -43,7 +43,6 @@
         # leaving the import support intact, doesn't hurt.
         self.name_for_meth = {} # get nicer wrapper names
         self.is_method = {}
-        self.use_true_methods = False # may be overridden
 
     def nameof(self, obj, debug=None):
         if debug:
@@ -586,13 +585,8 @@
                         if ann.binding(graph.getargs()[0]).classdef is not clsdef:
                             value = new_method_graph(graph, clsdef, fname, self.translator)
                     self.name_for_meth[value] = fname
-                    if self.use_true_methods:
-                        self.is_method[value] = True
                 elif isinstance(value, property):
                     fget, fset, fdel, doc = value.fget, value.fset, value.fdel, value.__doc__
-                    for f in fget, fset, fdel:
-                        if f and self.use_true_methods:
-                            self.is_method[f] = True
                     stuff = [self.nameof(x) for x in fget, fset, fdel, doc]
                     yield '%s.%s = property(%s, %s, %s, %s)' % ((name, key) +
                                                                 tuple(stuff))
@@ -625,9 +619,6 @@
 
     def nameof_property(self, p):
         fget, fset, fdel, doc = p.fget, p.fset, p.fdel, p.__doc__
-        for f in fget, fset, fdel:
-            if f and self.use_true_methods:
-                self.is_method[f] = True
         stuff = [self.nameof(x) for x in fget, fset, fdel, doc]
         name = self.uniquename('gprop')
         expr = 'property(%s, %s, %s, %s)' % (tuple(stuff))



More information about the Pypy-commit mailing list