summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Fix compiler warning about obviously unreachable code.Raymond Hettinger2016-01-251-4/+0
|
* Convert another post-decrement while-loop to pre-decrement for consistencyRaymond Hettinger2016-01-241-1/+2
| | | | and better generated code (on both GCC and CLang).
* Convert two other post-decrement while-loops to pre-decrements for consistencyRaymond Hettinger2016-01-241-2/+4
| | | | and for better code generation.
* Miscellaneous refactoringsRaymond Hettinger2016-01-241-65/+58
| | | | | | | | * Add comment to the maxlen structure entry about the meaning of maxlen == -1 * Factor-out code common to deque_append(left) and deque_extend(left) * Factor inner-loop in deque_clear() to use only 1 test per loop instead of 2 * Tighten inner-loops for deque_item() and deque_ass_item() so that the compiler can combine the decrement and test into a single step.
* Issue #26146: marshal.loads() now uses the empty frozenset singletonVictor Stinner2016-01-232-29/+47
|
* Cleanup test_dictVictor Stinner2016-01-231-5/+8
| | | | | | * Write one import per line * Sort imports by name * Add an empty line: 2 empty lines between code blocks at the module level (PEP 8)
* test_gc: remove unused importsVictor Stinner2016-01-231-2/+0
|
* Issue #18018: Raise an ImportError if a relative import is attemptedBrett Cannon2016-01-234-3/+20
| | | | | | | | with no known parent package. Previously SystemError was raised if the parent package didn't exist (e.g., __package__ was set to ''). Thanks to Florent Xicluna and Yongzhi Pan for reporting the issue.
* Issue #25234: Skip test_eintr.test_open() under OS X to avoid hangingBrett Cannon2016-01-221-0/+1
|
* whitespace cleanupBrett Cannon2016-01-221-2/+2
|
* Issue #25791: Warn when __package__ != __spec__.parent.Brett Cannon2016-01-228-120/+183
| | | | | | | | | In a previous change, __spec__.parent was prioritized over __package__. That is a backwards-compatibility break, but we do eventually want __spec__ to be the ground truth for module details. So this change reverts the change in semantics and instead raises an ImportWarning when __package__ != __spec__.parent to give people time to adjust to using spec objects.
* Merge from 3.5Brett Cannon2016-01-221-1/+1
|\
| * Fix a typo in a code exampleBrett Cannon2016-01-221-1/+1
| |
* | Merge 3.5 (i18n doc, issue #25907)Victor Stinner2016-01-223-59/+59
|\ \ | |/
| * doc: i18n HTML templatesVictor Stinner2016-01-223-59/+59
| | | | | | | | | | | | | | Issue #25907: Use {% trans %} tags in HTML templates to ease the translation of the documentation. The tag comes from Jinja templating system, used by Sphinx. Patch written by Julien Palard.
* | Null merge 3.5 (change already applied to default)Victor Stinner2016-01-220-0/+0
|\ \ | |/
| * code_richcompare() now uses the constants typesVictor Stinner2016-01-225-50/+246
| | | | | | | | | | | | | | | | | | Issue #25843: When compiling code, don't merge constants if they are equal but have a different types. For example, "f1, f2 = lambda: 1, lambda: 1.0" is now correctly compiled to two different functions: f1() returns 1 (int) and f2() returns 1.0 (int), even if 1 and 1.0 are equal. Add a new _PyCode_ConstantKey() private function.
* | Issue #25876: Fix also test_set() of test_gdb when -E command line is usedVictor Stinner2016-01-221-3/+6
| |
* | Issue #25876: test_gdb: use subprocess._args_from_interpreter_flags() to testVictor Stinner2016-01-221-4/+14
| | | | | | | | Python with more options.
* | Use Py_uintptr_t for atomic pointersVictor Stinner2016-01-223-30/+31
| | | | | | | | | | | | | | | | Issue #26161: Use Py_uintptr_t instead of void* for atomic pointers in pyatomic.h. Use atomic_uintptr_t when <stdatomic.h> is used. Using void* causes compilation warnings depending on which implementation of atomic types is used.
* | code_richcompare() now uses the constants typesVictor Stinner2016-01-225-50/+246
| | | | | | | | | | | | | | | | | | Issue #25843: When compiling code, don't merge constants if they are equal but have a different types. For example, "f1, f2 = lambda: 1, lambda: 1.0" is now correctly compiled to two different functions: f1() returns 1 (int) and f2() returns 1.0 (int), even if 1 and 1.0 are equal. Add a new _PyCode_ConstantKey() private function.
* | site: error on sitecustomize import errorVictor Stinner2016-01-222-6/+18
| | | | | | | | | | | | Issue #26099: The site module now writes an error into stderr if sitecustomize module can be imported but executing the module raise an ImportError. Same change for usercustomize.
* | merge 3.5Benjamin Peterson2016-01-221-0/+4
|\ \ | |/
| * merge 3.4Benjamin Peterson2016-01-221-0/+4
| |\
| | * reject negative data_sizeBenjamin Peterson2016-01-221-0/+4
| | |
* | | merge from 3.5Senthil Kumaran2016-01-221-2/+2
|\ \ \ | |/ / | | | | | | | | | | | | minor clarification on Zipfile 'x' mode - exclusive creation of a file. (Based on the feedback from docs@python.org list)
| * | minor clarification on Zipfile 'x' mode - exclusive creation of a file.Senthil Kumaran2016-01-221-2/+2
| | |
* | | Merge update to pipDonald Stufft2016-01-222-1/+1
|\ \ \ | |/ /
| * | Merge update to pipDonald Stufft2016-01-222-1/+1
| |\ \ | | |/
| | * Upgrade pip to 8.0.2Donald Stufft2016-01-222-1/+1
| | |
* | | Issue #18620: Improve Pool examples in multiprocessing documentationBerker Peksag2016-01-211-11/+26
|\ \ \ | |/ / | | | | | | | | | | | | | | | | | | | | | | | | A single call to Pool.apply_async() will create only one process. To use all of the pool's processes, it should be invoked multiple times: with Pool(processes=4) as pool: results = [pool.apply_async(func, ()) for i in range(4)] Patch by Davin Potts.
| * | Issue #18620: Improve Pool examples in multiprocessing documentationBerker Peksag2016-01-211-11/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A single call to Pool.apply_async() will create only one process. To use all of the pool's processes, it should be invoked multiple times: with Pool(processes=4) as pool: results = [pool.apply_async(func, ()) for i in range(4)] Patch by Davin Potts.
* | | merge from 3.5Senthil Kumaran2016-01-212-14/+14
|\ \ \ | |/ / | | | | | | | | | | | | | | | issue25909 - Correct the documentation of PyMapping_Items, PyMapping_Keys and PyMapping_Values in Include/abstract.h and Doc/c-api/mapping.rst. Patch contributed by Sonali Gupta.
| * | issue25909 - Correct the documentation of PyMapping_Items, PyMapping_Keys andSenthil Kumaran2016-01-212-14/+14
| | | | | | | | | | | | | | | | | | PyMapping_Values in Include/abstract.h and Doc/c-api/mapping.rst. Patch contributed by Sonali Gupta.
* | | Issue #26107: Fix typo in Objects/lnotab_notes.txtVictor Stinner2016-01-211-6/+6
| | | | | | | | | | | | Double parenthesis
* | | Merge 3.5 (doc)Victor Stinner2016-01-212-177/+184
|\ \ \ | |/ /
| * | Issue #26106: doc: Move text of licenses to parsed literal blockVictor Stinner2016-01-212-177/+184
| | | | | | | | | | | | | | | | | | | | | This change helps to ignore text of PSF, BEOPEN.com and CNRI licenses when translating the documentation. Patch written by Julien Palard who is translating Python 3.5 doc to french. Text of other licenses already used preformatted format.
* | | merge 3.5 (#26171)Benjamin Peterson2016-01-212-0/+8
|\ \ \ | |/ /
| * | merge 3.4 (#26171)Benjamin Peterson2016-01-212-0/+8
| |\ \ | | |/
| | * prevent buffer overflow in get_data (closes #26171)Benjamin Peterson2016-01-212-0/+8
| | |
* | | merge 3.5Benjamin Peterson2016-01-211-0/+1
|\ \ \ | |/ /
| * | merge 3.4Benjamin Peterson2016-01-211-0/+1
| |\ \ | | |/
| | * fix refleak in error conditionBenjamin Peterson2016-01-211-0/+1
| | |
* | | merge 3.5 (#26172)Benjamin Peterson2016-01-211-1/+1
|\ \ \ | |/ /
| * | merge 3.4 (#26172)Benjamin Peterson2016-01-211-1/+1
| |\ \ | | |/
| | * remove script from epub (closes #26172)Benjamin Peterson2016-01-211-1/+1
| | |
* | | Merge 3.5 (issue #24520)Victor Stinner2016-01-201-6/+2
|\ \ \ | |/ /
| * | Replace fpgetmask() with fedisableexcept()Victor Stinner2016-01-201-6/+2
| | | | | | | | | | | | | | | Issue #24520: On FreeBSD, fpgetmask() was deprecated long time ago. fedisableexcept() is now preferred.
* | | co_lnotab supports negative line number deltaVictor Stinner2016-01-2011-161/+203
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Issue #26107: The format of the co_lnotab attribute of code objects changes to support negative line number delta. Changes: * assemble_lnotab(): if line number delta is less than -128 or greater than 127, emit multiple (offset_delta, lineno_delta) in co_lnotab * update functions decoding co_lnotab to use signed 8-bit integers - dis.findlinestarts() - PyCode_Addr2Line() - _PyCode_CheckLineNumber() - frame_setlineno() * update lnotab_notes.txt * increase importlib MAGIC_NUMBER to 3361 * document the change in What's New in Python 3.6 * cleanup also PyCode_Optimize() to use better variable names
* | | merge from 3.5Senthil Kumaran2016-01-201-15/+17
|\ \ \ | |/ / | | | | | | issue25982 - Add a class definition for managers.Namespace in the multiprocessing docs.