[pypy-svn] r42444 - pypy/dist/pypy/translator/oosupport

antocuni at codespeak.net antocuni at codespeak.net
Sun Apr 29 21:06:09 CEST 2007


Author: antocuni
Date: Sun Apr 29 21:06:07 2007
New Revision: 42444

Modified:
   pypy/dist/pypy/translator/oosupport/function.py
Log:
make sure that the database knows about the types involed in each sub-operation



Modified: pypy/dist/pypy/translator/oosupport/function.py
==============================================================================
--- pypy/dist/pypy/translator/oosupport/function.py	(original)
+++ pypy/dist/pypy/translator/oosupport/function.py	Sun Apr 29 21:06:07 2007
@@ -252,6 +252,12 @@
         assert instr_list is not None, 'Unknown opcode: %s ' % op
         assert isinstance(instr_list, InstructionList)
         assert instr_list[-1] is StoreResult, "Cannot inline an operation that doesn't store the result"
+
+        # record that we know about the type of result and args
+        self.cts.lltype_to_cts(op.result.concretetype)
+        for v in op.args:
+            self.cts.lltype_to_cts(v.concretetype)
+
         instr_list = InstructionList(instr_list[:-1]) # leave the value on the stack if this is a sub-op
         instr_list.render(self.generator, op)
         # now the value is on the stack


More information about the pypy-svn mailing list