Author: Maciej Fijalkowski <[email protected]>
Branch: 
Changeset: r63249:fa879c4fc72f
Date: 2013-04-11 23:47 +0200
http://bitbucket.org/pypy/pypy/changeset/fa879c4fc72f/

Log:    add one extra assert here

diff --git a/rpython/rtyper/rlist.py b/rpython/rtyper/rlist.py
--- a/rpython/rtyper/rlist.py
+++ b/rpython/rtyper/rlist.py
@@ -952,6 +952,7 @@
     ll_assert(start <= l1.ll_length(), "l[start:x] = l with start > len(l)")
     ll_assert(count == stop - start,
                  "setslice cannot resize lists in RPython")
+    ll_assert(stop <= l1.ll_length(), "stop cannot be past the end of l1")
     # XXX ...but it would be easy enough to support if really needed
     ll_arraycopy(l2, l1, 0, start, count)
 ll_listsetslice.oopspec = 'list.setslice(l1, start, stop, l2)'
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to