Author: Armin Rigo <ar...@tunes.org> Branch: Changeset: r81580:256ca06a4fb1 Date: 2016-01-05 13:50 +0000 http://bitbucket.org/pypy/pypy/changeset/256ca06a4fb1/
Log: Fix the complexity in cPickle.py too (there's a mostly-duplicate?) diff --git a/lib_pypy/cPickle.py b/lib_pypy/cPickle.py --- a/lib_pypy/cPickle.py +++ b/lib_pypy/cPickle.py @@ -559,6 +559,7 @@ def decode_long(data): r"""Decode a long from a two's complement little-endian binary string. + This is overriden on PyPy by a RPython version that has linear complexity. >>> decode_long('') 0L @@ -592,6 +593,11 @@ n -= 1L << (nbytes << 3) return n +try: + from __pypy__ import decode_long +except ImportError: + pass + def load(f): return Unpickler(f).load() _______________________________________________ pypy-commit mailing list pypy-commit@python.org https://mail.python.org/mailman/listinfo/pypy-commit