Author: Lukas Diekmann <lukas.diekm...@uni-duesseldorf.de> Branch: list-strategies Changeset: r47532:94348703e47e Date: 2011-09-02 13:33 +0200 http://bitbucket.org/pypy/pypy/changeset/94348703e47e/
Log: quicksort rpython fix diff --git a/pypy/objspace/std/listobject.py b/pypy/objspace/std/listobject.py --- a/pypy/objspace/std/listobject.py +++ b/pypy/objspace/std/listobject.py @@ -760,8 +760,7 @@ def custom_sort_for_ints(self, w_list): l = self.cast_from_void_star(w_list.lstorage) - print l - self.quicksort(l) + self.quicksort(l, 0, len(l) - 1) def partition(self, l, start, end): left = start @@ -784,12 +783,7 @@ return left - def quicksort(self, l, start=None, end=None): - if start is None: - start = 0 - if end is None: - end = len(l) - 1 - + def quicksort(self, l, start, end): if start < end: p = self.partition(l, start, end) self.quicksort(l, start, p - 1) _______________________________________________ pypy-commit mailing list pypy-commit@python.org http://mail.python.org/mailman/listinfo/pypy-commit