[pypy-svn] r55197 - pypy/dist/pypy/interpreter/astcompiler

afa at codespeak.net afa at codespeak.net
Sat May 24 23:52:53 CEST 2008


Author: afa
Date: Sat May 24 23:52:52 2008
New Revision: 55197

Modified:
   pypy/dist/pypy/interpreter/astcompiler/opt.py
Log:
This may depend on annotation order, but I regularly get this error::

    Blocked block -- operation cannot succeed
     v0 = getattr(self_0, ('is_and'))
    Known variable annotations:
    self_0 = SomeInstance(can_be_None=False, classdef=pypy.interpreter.astcompiler.ast.AbstractTest)

Attaching the attribute to the base class seems good practice anyway.


Modified: pypy/dist/pypy/interpreter/astcompiler/opt.py
==============================================================================
--- pypy/dist/pypy/interpreter/astcompiler/opt.py	(original)
+++ pypy/dist/pypy/interpreter/astcompiler/opt.py	Sat May 24 23:52:52 2008
@@ -75,7 +75,7 @@
         __metaclass__ = extendabletype
         is_and = True
 
-    class __extend__(ast.Or):
+    class __extend__(ast.AbstractTest):
         __metaclass__ = extendabletype
         is_and = False
 



More information about the Pypy-commit mailing list