summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Changed Karatsuba cutoff to match current reality.Tim Peters2004-08-301-1/+1
|
* More cmd.exe exploitation.Tim Peters2004-08-301-38/+50
|
* Since it's impossible to build Python using VC7.1 on a command.comTim Peters2004-08-301-6/+1
| | | | system, exploit cmd.exe's setlocal function in this directory.
* Updated test-runner .bat for new location of Tcl/Tk.Tim Peters2004-08-302-8/+6
| | | | | | | Replaced outcomes from native Tcl/Tk tests. Maybe the diffs are legit, maybe not. I noticed that the Tcl results I'm replacing here claimed both that there were no failures, and that one file had tests with failures, so I wasn't inclined to trust them <wink>.
* win32_urandom(): There's no need to copy the generated byte string, soTim Peters2004-08-301-17/+11
| | | | don't.
* win32_urandom(): pass the function name to PyArg_ParseTuple, for betterTim Peters2004-08-301-1/+1
| | | | error msgs.
* win32_urandom(): Raise ValueError if the argument is negative.Tim Peters2004-08-301-0/+3
|
* win32_urandom(): Rewrite to Python C standards (hard tabs, function nameTim Peters2004-08-301-52/+59
| | | | in first column, no parens around return value).
* The distinction between comparison flags and reporting flags isn't uniqueTim Peters2004-08-302-29/+29
| | | | | | | | | | | to unittest, so make it official: new module constants COMPARISON_FLAGS and REPORTING_FLAGS, which are bitmasks or'ing together the relevant individual option flags. set_unittest_reportflags(): Reworked to use REPORTING_FLAGS, and simplified overly complicated flag logic. class FakeModule: Removed this; neither documented nor used.
* Fix build error: \filename{/dev/urandom} -> \file{/dev/urandom}.Johannes Gijsbers2004-08-301-1/+1
|
* Bug #1014775: update NEWS.help for changes in docutils.Johannes Gijsbers2004-08-301-2/+2
|
* Bug #1014770: apply some rest-foo and fix some docutils errors.Johannes Gijsbers2004-08-301-1/+9
|
* Patch #934356: if a module defines __all__, believe that rather than usingJohannes Gijsbers2004-08-302-4/+15
| | | | heuristics for filtering out imported names.
* Whitespace normalization.Johannes Gijsbers2004-08-301-1/+1
|
* Patch #1003640: replace checkline() function parsing with new breakpoint logic:Johannes Gijsbers2004-08-302-45/+51
| | | | | | | | | | | | | 1) When a breakpoint is set via a function name: - the breakpoint gets the lineno of the def statement - a new funcname attribute is attached to the breakpoint 2) bdb.effective() calls new function checkfuncname() to handle: - def statement is executed: don't break. - a first executable line of a function with a breakpoint on the lineno of the def statement is reached: break. This fixes bugs 976878, 926369 and 875404. Thanks Ilya Sandler.
* Add itemsAndrew M. Kuchling2004-08-301-0/+14
|
* Patch #941486: add os.path.lexists(). Also fix bug #940578 by using lexists ↵Johannes Gijsbers2004-08-3011-4/+57
| | | | in glob.glob.
* Pickup Tk from tcltk directory.Martin v. Löwis2004-08-301-5/+7
|
* Bump Tk version to 8.4.7. Build into tcltk directory.Martin v. Löwis2004-08-302-36/+28
|
* Teach the random module about os.urandom().Raymond Hettinger2004-08-304-10/+183
| | | | | * Use it for seeding when it is available. * Provide an alternate generator based on it.
* long_pow(): Fix more instances of leaks in error cases.Tim Peters2004-08-301-3/+3
| | | | | Bugfix candidate -- although long_pow() is so different now I doubt a patch would apply to 2.3.
* SF patch 936813: fast modular exponentiationTim Peters2004-08-303-109/+204
| | | | | | | | | | | | | | | | | | | | | | | | This checkin is adapted from part 2 (of 3) of Trevor Perrin's patch set. BACKWARD INCOMPATIBILITY: SHIFT must now be divisible by 5. AFAIK, nobody will care. long_pow() could be complicated to worm around that, if necessary. long_pow(): - BUGFIX: This leaked the base and power when the power was negative (and so the computation delegated to float pow). - Instead of doing right-to-left exponentiation, do left-to-right. This is more efficient for small bases, which is the common case. - In addition, if the exponent is large (more than FIVEARY_CUTOFF digits), precompute [a**i % c for i in range(32)], and go left to right 5 bits at a time. l_divmod(): - The signature changed so that callers who don't want the quotient, or don't want the remainder, can pass NULL in the slot they don't want. This saves them from having to declare a vrbl for unwanted stuff, and remembering to decref it. long_mod(), long_div(), long_classic_div(): - Adjust to new l_divmod() signature, and simplified as a result.
* Whitespace normalization. test_difflib passes again.Tim Peters2004-08-293-101/+101
|
* SF patch 936813: fast modular exponentiationTim Peters2004-08-294-22/+91
| | | | | | | | | | | | | | | | | | This checkin is adapted from part 1 (of 3) of Trevor Perrin's patch set. x_mul() - sped a little by optimizing the C - sped a lot (~2X) if it's doing a square; note that long_pow() squares often k_mul() - more cache-friendly now if it's doing a square KARATSUBA_CUTOFF - boosted; gradeschool mult is quicker now, and it may have been too low for many platforms anyway KARATSUBA_SQUARE_CUTOFF - new - since x_mul is a lot faster at squaring now, the point at which Karatsuba pays for squaring is much higher than for general mult
* Reverting whitespace normalization. test_difflib fails with it -- theTim Peters2004-08-292-47/+47
| | | | | test depends on invisible trailing whitespace in .py files. The author will have to repair that.
* Whitespace normalization.Tim Peters2004-08-294-52/+52
|
* Patch #727483: Add AUTH_TYPE and REMOTE_USER.Martin v. Löwis2004-08-291-2/+15
|
* Patch #973204: Use -rpath instead of -R on Irix and Tru64.Martin v. Löwis2004-08-292-1/+7
|
* Patch #914575: difflib side by side diff support, diff.py s/b/s HTML option.Martin v. Löwis2004-08-297-7/+1412
|
* Centralize WITH_TSC processing.Martin v. Löwis2004-08-291-37/+3
|
* Patch #934711: Expose platform-specific entropy.Martin v. Löwis2004-08-295-1/+126
|
* SF feature request #992967: array.array objects should support sequences.Raymond Hettinger2004-08-294-13/+63
| | | | Made the constructor accept general iterables.
* Whitespace normalization.Tim Peters2004-08-292-10/+10
|
* Added an __iter__ method for test suites.Jim Fulton2004-08-282-0/+34
|
* setUp and tearDown functions are now passed the test objectJim Fulton2004-08-281-2/+2
|
* - setUp and tearDown functions are now passed the test objectJim Fulton2004-08-282-22/+235
| | | | | - Added a set_unittest_reportflags to set default reporting flags used when running doctests under unittest control.
* PyUnicode_Join(): Bozo Alert. While this is chugging along, it mayTim Peters2004-08-271-0/+12
| | | | | | | | | need to convert str objects from the iterable to unicode. So, if someone set the system default encoding to something nasty enough, the conversion process could mutate the input iterable as a side effect, and PySequence_Fast doesn't hide that from us if the input was a list. IOW, can't assume the size of PySequence_Fast's result is invariant across PyUnicode_FromObject() calls.
* PyUnicode_Join(): Rewrote to use PySequence_Fast(). This doesn't doTim Peters2004-08-271-126/+96
| | | | | | | | much to reduce the size of the code, but greatly improves its clarity. It's also quicker in what's probably the most common case (the argument iterable is a list). Against it, if the iterable isn't a list or a tuple, a temp tuple is materialized containing the entire input sequence, and that's a bigger temp memory burden. Yawn.
* Removed old "if 0:" block for leak detection; wouldn't work anymore anyway.Tim Peters2004-08-271-8/+1
|
* Don't really need ellipsis doctests for the syntax errors, becauseTim Peters2004-08-271-12/+12
| | | | | | this module imports itself explicitly from test (so the "file names" current doctest synthesizes for examples don't vary depending on how test_generators is run).
* Removed outdated commentEdward Loper2004-08-271-2/+0
|
* Fixed 6 failures due to doctest changes.Tim Peters2004-08-271-16/+16
|
* test_bug1001011(): Verify thatTim Peters2004-08-271-5/+33
| | | | | | | | | s.join([t]) is t for (s, t) in (str, str), (unicode, unicode), and (str, unicode). For (unicode, str), verify that it's *not* t (the result is promoted to unicode instead). Also verify that when t is a subclass of str or unicode that "the right thing" happens.
* PyUnicode_Join(): Missed a spot where I intended a cast from size_t toTim Peters2004-08-271-1/+1
| | | | | int. I sure wish MS would gripe about that! Whatever, note that the statement above it guarantees that the cast loses no info.
* Fix the spelling of Fredrik Lundh's last name (unless there really is aBrett Cannon2004-08-271-1/+1
| | | | "Fredrik Lund" who contributed the code in question).
* Remove unused method _OutputRedirectingPdb.resumeEdward Loper2004-08-271-3/+0
|
* - Removed redundant call to expandtabs in DocTestParesr.Edward Loper2004-08-272-67/+175
| | | | | | | | | | | | | | - Improvements to interactive debugging support: - Changed the replacement pdb.set_trace to redirect stdout to the real stdout *only* during interactive debugging; stdout from code continues to go to the fake stdout. - When the interactive debugger gets to the end of an example, automatically continue. - Use a replacement linecache.getlines that will return source lines from doctest examples; this makes the source available to the debugger for interactive debugging. - In test_doctest, use a specialized _FakeOutput class instead of a temporary file to fake stdin for the interactive interpreter.
* PyUnicode_Join(): Two primary aims:Tim Peters2004-08-271-40/+120
| | | | | | | | 1. u1.join([u2]) is u2 2. Be more careful about C-level int overflow. Since PySequence_Fast() isn't needed to achieve #1, it's not used -- but the code could sure be simpler if it were.
* - Added DocTestParser.parse(), which parses a docstring into ExamplesEdward Loper2004-08-262-145/+137
| | | | | | | | | and intervening text strings. - Removed DocTestParser.get_program(): use script_from_examples() instead. - Fixed bug in DocTestParser._INDENT_RE - Fixed bug in DocTestParser._min_indent - Moved _want_comment() to the utility function section
* Move test_bug1001011() to string_tests.MixinStrUnicodeTest so thatWalter Dörwald2004-08-264-24/+23
| | | | | | it can be used for str and unicode. Drop the test for "".join([s]) is s because this is an implementation detail (and doesn't work for unicode)