[pypy-svn] r46187 - pypy/branch/pypy-more-rtti-inprogress/rpython
fijal at codespeak.net
fijal at codespeak.net
Thu Aug 30 12:31:53 CEST 2007
Author: fijal
Date: Thu Aug 30 12:31:52 2007
New Revision: 46187
Modified:
pypy/branch/pypy-more-rtti-inprogress/rpython/extfunc.py
Log:
* Have a default stringpolicy (eventually)
* always copy kwds
Modified: pypy/branch/pypy-more-rtti-inprogress/rpython/extfunc.py
==============================================================================
--- pypy/branch/pypy-more-rtti-inprogress/rpython/extfunc.py (original)
+++ pypy/branch/pypy-more-rtti-inprogress/rpython/extfunc.py Thu Aug 30 12:31:52 2007
@@ -104,6 +104,7 @@
self.__dict__.update(platform.configure(CConfig))
def llexternal(self, *args, **kwds):
+ kwds = kwds.copy()
from pypy.rpython.lltypesystem import rffi
for item in self.__ATTRIBUTES:
@@ -111,6 +112,9 @@
kwds[item] = getattr(self, '_%s_' % item, [])
else:
kwds[item] += getattr(self, '_%s_' % item, [])
+ stringpolicy = getattr(self, '_stringpolicy_', None)
+ if stringpolicy and 'stringpolicy' not in kwds:
+ kwds['stringpolicy'] = stringpolicy
return rffi.llexternal(*args, **kwds)
class genericcallable(object):
More information about the Pypy-commit
mailing list