[pypy-svn] r7410 - pypy/trunk/src/pypy/annotation
hpk at codespeak.net
hpk at codespeak.net
Fri Nov 19 09:45:57 CET 2004
Author: hpk
Date: Fri Nov 19 09:45:56 2004
New Revision: 7410
Modified:
pypy/trunk/src/pypy/annotation/builtin.py
pypy/trunk/src/pypy/annotation/factory.py
pypy/trunk/src/pypy/annotation/model.py
Log:
finally rename BUILTIN_FUNCTIONS to BUILTIN_ANALYZERS
Modified: pypy/trunk/src/pypy/annotation/builtin.py
==============================================================================
--- pypy/trunk/src/pypy/annotation/builtin.py (original)
+++ pypy/trunk/src/pypy/annotation/builtin.py Fri Nov 19 09:45:56 2004
@@ -106,11 +106,11 @@
# collect all functions
import __builtin__
-BUILTIN_FUNCTIONS = {}
+BUILTIN_ANALYZERS = {}
for name, value in globals().items():
if name.startswith('builtin_'):
original = getattr(__builtin__, name[8:])
- BUILTIN_FUNCTIONS[original] = value
+ BUILTIN_ANALYZERS[original] = value
-BUILTIN_FUNCTIONS[pypy.objspace.std.restricted_int.r_int] = builtin_int
-BUILTIN_FUNCTIONS[pypy.objspace.std.restricted_int.r_uint] = restricted_uint
+BUILTIN_ANALYZERS[pypy.objspace.std.restricted_int.r_int] = builtin_int
+BUILTIN_ANALYZERS[pypy.objspace.std.restricted_int.r_uint] = restricted_uint
Modified: pypy/trunk/src/pypy/annotation/factory.py
==============================================================================
--- pypy/trunk/src/pypy/annotation/factory.py (original)
+++ pypy/trunk/src/pypy/annotation/factory.py Fri Nov 19 09:45:56 2004
@@ -282,4 +282,4 @@
for factory in self.getallfactories():
bookkeeper.annotator.reflowfromposition(factory.position_key)
-from pypy.annotation.builtin import BUILTIN_FUNCTIONS
+from pypy.annotation.builtin import BUILTIN_ANALYZERS
Modified: pypy/trunk/src/pypy/annotation/model.py
==============================================================================
--- pypy/trunk/src/pypy/annotation/model.py (original)
+++ pypy/trunk/src/pypy/annotation/model.py Fri Nov 19 09:45:56 2004
@@ -227,8 +227,8 @@
for key, value in x.items():
items[key] = immutablevalue(value)
result = SomeDict({}, items)
- elif ishashable(x) and x in BUILTIN_FUNCTIONS:
- result = SomeBuiltin(BUILTIN_FUNCTIONS[x])
+ elif ishashable(x) and x in BUILTIN_ANALYZERS:
+ result = SomeBuiltin(BUILTIN_ANALYZERS[x])
elif callable(x) or isinstance(x, staticmethod): # XXX
if hasattr(x, '__self__') and x.__self__ is not None:
s_self = immutablevalue(x.__self__)
@@ -303,4 +303,4 @@
# this has the side-effect of registering the unary and binary operations
from pypy.annotation.unaryop import UNARY_OPERATIONS
from pypy.annotation.binaryop import BINARY_OPERATIONS
-from pypy.annotation.builtin import BUILTIN_FUNCTIONS
+from pypy.annotation.builtin import BUILTIN_ANALYZERS
More information about the Pypy-commit
mailing list