summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_xrange.py
Commit message (Collapse)AuthorAgeFilesLines
* Issues #16029, #16030: Fix pickling and repr of large xranges.Mark Dickinson2012-09-281-0/+75
|
* Merged revisions 86596 via svnmerge fromEzio Melotti2010-11-211-2/+2
| | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r86596 | ezio.melotti | 2010-11-20 21:04:17 +0200 (Sat, 20 Nov 2010) | 1 line #9424: Replace deprecated assert* methods in the Python test suite. ........
* use assert[Not]In where appropriateEzio Melotti2010-01-231-6/+6
|
* Issue #5080: turn the DeprecationWarning from float arguments passedMark Dickinson2010-01-011-1/+1
| | | | | | to integer PyArg_Parse* format codes into a TypeError. Add a DeprecationWarning for floats passed with the 'L' format code, which didn't previously have a warning.
* Avoid signed overflow in some xrange calculations, and extendMark Dickinson2009-11-151-0/+68
| | | | | | xrange tests to cover some special cases that caused problems in py3k. This is a partial backport of r76292-76293 (see issue #7298.)
* convert usage of fail* to assert*Benjamin Peterson2009-06-301-6/+6
|
* Issue #4183: Some tests didn't run with pickle.HIGHEST_PROTOCOL.Hirokazu Yamamoto2008-10-231-1/+1
|
* Added better pickling support to xrange objects.Alexandre Vassalotti2008-06-101-9/+10
| | | | Cleaned up the unit test.
* Issue 2582: Fix pickling of xrange objects.Alexandre Vassalotti2008-06-101-0/+10
|
* Make xrange more Py_ssize_t aware, by assuming a Py_ssize_t is always atThomas Wouters2006-04-041-6/+1
| | | | | | | | | | | least as big as a long. I believe this to be a safe assumption that is being made in many parts of CPython, but a check could be added. len(xrange(sys.maxint)) works now, so fix the testsuite's odd exception for 64-bit platforms too. It also fixes 'zip(xrange(sys.maxint), it)' as a portable-ish (if expensive) alternative to enumerate(it); since zip() now calls len(), this was breaking on (real) 64-bit platforms. No additional test was added for that behaviour.
* Get test to pass on amd64 (opteron). This is pretty hacky, butNeal Norwitz2004-10-141-2/+7
| | | | rangeobject.c has an #ifdef that is reached only when LONG_MAX != INT_MAX
* Bug 1003935: xrange overflowsTim Peters2004-08-081-1/+6
| | | | | | | | | | | | | | | Added XXX comment about why the undocumented PyRange_New() API function is too broken to be worth the considerable pain of repairing. Changed range_new() to stop using PyRange_New(). This fixes a variety of bogus errors. Nothing in the core uses PyRange_New() now. Documented that xrange() is intended to be simple and fast, and that CPython restricts its arguments, and length of its result sequence, to native C longs. Added some tests that failed before the patch, and repaired a test that relied on a bogus OverflowError getting raised.
* Exercise xrange a bitNeal Norwitz2004-07-081-0/+59