[pypy-svn] r54706 - pypy/branch/hybrid-io/pypy/objspace/std

fijal at codespeak.net fijal at codespeak.net
Tue May 13 17:07:46 CEST 2008


Author: fijal
Date: Tue May 13 17:07:44 2008
New Revision: 54706

Modified:
   pypy/branch/hybrid-io/pypy/objspace/std/stringobject.py
Log:
There is an assumption that init_size needs to be constant. There is no good
reason for that, but fix translation.


Modified: pypy/branch/hybrid-io/pypy/objspace/std/stringobject.py
==============================================================================
--- pypy/branch/hybrid-io/pypy/objspace/std/stringobject.py	(original)
+++ pypy/branch/hybrid-io/pypy/objspace/std/stringobject.py	Tue May 13 17:07:44 2008
@@ -861,7 +861,7 @@
 def repr__String(space, w_str):
     s = w_str._value
 
-    buf = StringBuilder(len(s) + 10)
+    buf = StringBuilder(50) # XXX this needs to be constant, fix
 
     quote = "'"
     if quote in s and '"' not in s:



More information about the Pypy-commit mailing list