Raymond Hettinger
90dea4ce43
Tweak the deque struct by moving the least used fields (maxlen and weakref) to the end.
2013-07-13 22:30:25 -07:00
Raymond Hettinger
840533bf1c
Use a do-while loop in the inner loop for rotate (m is always greater than zero).
2013-07-13 17:03:58 -07:00
Raymond Hettinger
3959af9b2a
Move the freeblock() call outside the main loop to speed-up and simplify the block re-use logic.
2013-07-13 02:34:08 -07:00
Terry Jan Reedy
ae13ff1c5f
Merge with 3.3
2013-07-13 04:06:03 -04:00
Terry Jan Reedy
e6a17862e7
Issue #18365 : convert buildbot errors to skips.
2013-07-13 04:05:42 -04:00
Terry Jan Reedy
371f746bdc
Merge with 3.3
2013-07-13 02:35:07 -04:00
Terry Jan Reedy
4f133e2e98
Issue #18279 : Add tests for idlelib/RstripExtension.py. Original patch by
...
Phil Webster. With that available, modify RstripExtension.py to stop deleting
null slices, which caused a file to be marked as changed when it was not.
2013-07-13 02:34:43 -04:00
R David Murray
1424e7d688
Merge: #18437 : fix comment typo.
2013-07-12 22:56:15 -04:00
R David Murray
037f65841c
#18437 : fix comment typo.
2013-07-12 22:55:43 -04:00
Terry Jan Reedy
4064b2448c
Merge with 3.3
2013-07-12 20:17:00 -04:00
Terry Jan Reedy
04ff0382b2
Issue #18365 : normalize whitespace
2013-07-12 20:16:28 -04:00
Terry Jan Reedy
0c92553d85
Merge with 3.3
2013-07-12 20:10:48 -04:00
Terry Jan Reedy
21784da416
Issue #18365 : Add mock Text class and test thereof versus tk.Text.
...
Based on patches by Todd.Rovito and Phil Webster.
2013-07-12 20:10:23 -04:00
R David Murray
d0a03ad139
#18389 : Clarify that relpath does not access the file system.
...
Initial patch by Madison May.
2013-07-12 17:43:53 -04:00
R David Murray
ce10fab9f6
#18389 : Clarify that relpath does not access the file system.
...
Initial patch by Madison May.
2013-07-12 17:43:11 -04:00
Vinay Sajip
11b38f17ca
Closes #18433 : Merged documentation update from 3.3.
2013-07-12 21:54:12 +01:00
Vinay Sajip
577d4ff6e0
Issue #18433 : Clarified venv documentation.
2013-07-12 21:52:51 +01:00
Vinay Sajip
c1a9d30354
Merged changes.
2013-07-12 21:46:05 +01:00
Vinay Sajip
ad6bb031d7
Issue #18434 : Updated example script to tidy up resources.
2013-07-12 21:44:35 +01:00
Vinay Sajip
8c7dde3bd9
Merged upstream changes.
2013-07-12 21:19:41 +01:00
Vinay Sajip
4969d468cb
Merged upstream changes.
2013-07-12 21:18:49 +01:00
Vinay Sajip
ad644e011f
Closes #18435 : Merged fix from 3.3.
2013-07-12 21:13:01 +01:00
Vinay Sajip
c07aa9e41f
Issue #18435 : Replaced simple attribute container class Context with types.SimpleNamespace.
2013-07-12 21:10:19 +01:00
R David Murray
a03a7c79ca
Merge heads.
2013-07-12 16:04:18 -04:00
R David Murray
8863bfe618
Merge heads.
2013-07-12 16:03:44 -04:00
R David Murray
1f9d24a18d
Merge: #18431 : Decode encoded words in atoms in new email parser.
2013-07-12 16:01:10 -04:00
R David Murray
923512f327
#18431 : Decode encoded words in atoms in new email parser.
...
There is more to be done here in terms of accepting RFC invalid
input that some mailers accept, but this covers the valid
RFC places where encoded words can occur in structured headers.
2013-07-12 16:00:28 -04:00
Vinay Sajip
62926eed68
Closes #18434 : Merged documentation update from 3.3.
2013-07-12 20:58:14 +01:00
Vinay Sajip
3c557f298a
Issue #18434 : Updated example script in venv docs to use setuptools rather than Distribute.
2013-07-12 20:54:25 +01:00
Brett Cannon
ae95b4f7a5
Issue #17845 : Clarify the message setup.py prints upon successfully
...
building Python but having some optional module which didn't build.
Patch by Yogesh Chaudhari.
2013-07-12 11:30:32 -04:00
Brett Cannon
a79e4fb38d
Issue #18342 : Use the repr of a module name for ``from ... import
...
...`` when an ImportError occurs.
Other cases had already been switched over to using the repr.
Thanks to Tomasz Maćkowiak for the patch.
2013-07-12 11:22:26 -04:00
Brett Cannon
f0cb69274c
Issue #18415 : Normalize what type of quotes are used with string
...
constants in importlib._bootstrap. Along the way clean up from string
interpolation to use the repr explicitly.
Initial patch by Madison May.
2013-07-12 11:04:23 -04:00
Victor Stinner
d917dcbe5e
Issue #18408 : Fix constructors of _elementtree.c
...
* Use Py_DECREF() instead of PyObject_GC_Del() to release correctly all
resources
* Raise MemoryError on memory allocation failure
2013-07-12 02:05:17 +02:00
Victor Stinner
81aac734e1
Issue #18408 : Fix create_extra() of _elementtree.c, raise MemoryError on memory
...
allocation failure
2013-07-12 02:03:34 +02:00
Victor Stinner
df4572cc71
Issue #18408 : parser module: fix error handling in node2tuple()
...
Handle PyLong_FromLong() and PyUnicode_FromString() failures
2013-07-12 01:35:10 +02:00
Victor Stinner
3bd6abd129
Issue #18408 : Fix parser.sequence2st() and parser.tuple2st(): raise MemoryError
...
on memory allocation failure
Instead of ignoring the memory allocation failure and create invalid objects.
2013-07-12 01:33:59 +02:00
Victor Stinner
4202456cd4
Issue #18408 : _pickle.c: Add missing PyErr_NoMemory() on memory allocation failures
2013-07-12 00:53:57 +02:00
Victor Stinner
8ca72e2e3d
Issue #18408 : _PyMemoTable_ResizeTable() now restores the old table if
...
allocating a bigger table failed
PyMemoTable destructor does crash if mt_table is NULL.
2013-07-12 00:53:26 +02:00
Victor Stinner
a41f085144
Issue #18408 : pmerge() help of mro_implementation() now raises MemoryError on
...
memory allocation failure
Replace also PyMem_Free() with PyMem_FREE() to be consistent with the rest of
the function.
2013-07-12 00:42:14 +02:00
Victor Stinner
fb3a630001
Issue #18408 : errors.c: in debug mode, calling PyErr_BadInternalCall() now
...
fails with an assertion error
2013-07-12 00:37:30 +02:00
Victor Stinner
365b693adc
Issue #18408 : ceval.c: in debug mode, convert the PyErr_Occurred() check on
...
exception (when getting NULL) to an assertion to detect bugs earlier
2013-07-12 00:11:58 +02:00
Victor Stinner
c31df04234
Issue #18408 : Oh, I was wrong: Pickler_New() must call Py_DECREF() to destroy
...
the newly created pickler, and not PyObject_GC_Del().
2013-07-12 00:08:59 +02:00
Victor Stinner
cc35159ed8
Issue #18408 : normalizestring() now raises MemoryError on memory allocation failure
2013-07-12 00:02:55 +02:00
Victor Stinner
9035ad932b
Issue #18408 : In debug mode, PyCFunction_Call() now checks if an exception was
...
raised if the result is NULL to help to find bugs in C mode (get the error
earlier than the SystemError in ceval.c).
2013-07-11 23:44:46 +02:00
Victor Stinner
526daabf34
Issue #18408 : parsetok() must not write into stderr on memory allocation error
...
The caller gets an error code and can raise a classic Python exception.
2013-07-11 23:17:33 +02:00
Victor Stinner
71c8b7ec04
Issue #18408 : Different fixes in _elementtree.c to handle correctly MemoryError
...
* create_new_element() initializes all attributes before handling errors,
to fix a crash in the destructor
* create_new_element() calls PyObject_GC_Del() on error, instead of
PyObject_Del(), because the object was created by PyObject_GC_New()
* subelement() now handles create_new_element() failure
* element_getattro() now handles element_get_text() failure
* makeuniversal() now handles PyBytes_FromStringAndSize() failure
2013-07-11 23:08:39 +02:00
Victor Stinner
4d46343340
Cleanup _elementtree.c
2013-07-11 23:05:03 +02:00
Victor Stinner
5f0af23f5e
Issue #18408 : _elementtree.c now handles create_extra() failure
2013-07-11 23:01:36 +02:00
Victor Stinner
68c8ea25f1
Issue #18408 : Fix _Pickler_New() and _Unpickler_New(): initialize all
...
attributes before handling errors
_Pickler_New() now calls PyObject_GC_Del() instead of Py_DECREF() on error,
because the pickle object is created using PyObject_GC_New().
Fix a crash in the destructor when an attribute is not initiallized.
2013-07-11 22:56:25 +02:00
Victor Stinner
3bf5f530d9
Issue #18408 : parsetok() must not write into stderr on memory allocation error
...
The caller gets an error code and can raise a classic Python exception.
2013-07-11 22:52:19 +02:00