Author: Benjamin Peterson <[email protected]>
Branch:
Changeset: r54053:ace5f809040a
Date: 2012-03-28 22:59 -0400
http://bitbucket.org/pypy/pypy/changeset/ace5f809040a/
Log: get correct behavior on JVM
diff --git a/pypy/rpython/ootypesystem/rstr.py
b/pypy/rpython/ootypesystem/rstr.py
--- a/pypy/rpython/ootypesystem/rstr.py
+++ b/pypy/rpython/ootypesystem/rstr.py
@@ -222,6 +222,8 @@
length = s.ll_strlen()
if stop > length:
stop = length
+ if start > stop:
+ start = stop
return s.ll_substring(start, stop-start)
def ll_stringslice_minusone(s):
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit