[pypy-svn] r49062 - pypy/dist/pypy/translator/llvm
rxe at codespeak.net
rxe at codespeak.net
Sun Nov 25 09:58:49 CET 2007
Author: rxe
Date: Sun Nov 25 09:58:48 2007
New Revision: 49062
Modified:
pypy/dist/pypy/translator/llvm/arraynode.py
pypy/dist/pypy/translator/llvm/codewriter.py
Log:
fix debug print
Modified: pypy/dist/pypy/translator/llvm/arraynode.py
==============================================================================
--- pypy/dist/pypy/translator/llvm/arraynode.py (original)
+++ pypy/dist/pypy/translator/llvm/arraynode.py Sun Nov 25 09:58:48 2007
@@ -17,11 +17,10 @@
return '%s c"%s\\00"' % (self.get_typerepr(), self.value)
def get_childref(self, index):
- x = "getelementptr(%s* %s, i32 0, i32 %s)" % (
+ return "getelementptr(%s* %s, i32 0, i32 %s)" % (
self.get_typerepr(),
self.name,
index)
- return 'bitcast(i8* %s to [0 x i8]*)' % x
def writeglobalconstants(self, codewriter):
codewriter.globalinstance(self.ref, self.constantvalue())
Modified: pypy/dist/pypy/translator/llvm/codewriter.py
==============================================================================
--- pypy/dist/pypy/translator/llvm/codewriter.py (original)
+++ pypy/dist/pypy/translator/llvm/codewriter.py Sun Nov 25 09:58:48 2007
@@ -210,5 +210,5 @@
var = self.db.repr_tmpvar()
node = self.db.create_debug_string(s)
self.call(var, "i32", "@write",
- ['i32', '[0 x i8]*', 'i32'],
- ['2', node.get_childref(0), '%d' % node.get_length()])
+ ['i32', 'i8*', 'i32'],
+ ['2', node.get_childref(0), '%d' % node.get_length()], cconv='ccc')
More information about the Pypy-commit
mailing list