# HG changeset patch # Parent ebb1a16de89b712010cd195a1e2331673836040a diff -r ebb1a16de89b Doc/c-api/unicode.rst --- a/Doc/c-api/unicode.rst Sat Apr 16 11:51:31 2016 +0000 +++ b/Doc/c-api/unicode.rst Sat Apr 16 14:05:08 2016 +0000 @@ -450,7 +450,7 @@ | :attr:`%%` | *n/a* | The literal % character. | +-------------------+---------------------+--------------------------------+ | :attr:`%c` | int | A single character, | - | | | represented as an C int. | + | | | represented as a C int. | +-------------------+---------------------+--------------------------------+ | :attr:`%d` | int | Exactly equivalent to | | | | ``printf("%d")``. | diff -r ebb1a16de89b Doc/library/shutil.rst --- a/Doc/library/shutil.rst Sat Apr 16 11:51:31 2016 +0000 +++ b/Doc/library/shutil.rst Sat Apr 16 14:05:08 2016 +0000 @@ -342,7 +342,7 @@ Return the path to an executable which would be run if the given *cmd* was called. If no *cmd* would be called, return ``None``. - *mode* is a permission mask passed a to :func:`os.access`, by default + *mode* is a permission mask passed to :func:`os.access`, by default determining if the file exists and executable. When no *path* is specified, the results of :func:`os.environ` are used, diff -r ebb1a16de89b Doc/library/tkinter.tix.rst --- a/Doc/library/tkinter.tix.rst Sat Apr 16 11:51:31 2016 +0000 +++ b/Doc/library/tkinter.tix.rst Sat Apr 16 14:05:08 2016 +0000 @@ -267,7 +267,7 @@ The `ExFileSelectBox `_ - widget is usually embedded in a tixExFileSelectDialog widget. It provides an + widget is usually embedded in a tixExFileSelectDialog widget. It provides a convenient method for the user to select files. The style of the :class:`ExFileSelectBox` widget is very similar to the standard file dialog on MS Windows 3.1. diff -r ebb1a16de89b Lib/_pyio.py --- a/Lib/_pyio.py Sat Apr 16 11:51:31 2016 +0000 +++ b/Lib/_pyio.py Sat Apr 16 14:05:08 2016 +0000 @@ -439,7 +439,7 @@ return self.__closed def _checkClosed(self, msg=None): - """Internal: raise an ValueError if file is closed + """Internal: raise a ValueError if file is closed """ if self.closed: raise ValueError("I/O operation on closed file." diff -r ebb1a16de89b Lib/email/_header_value_parser.py --- a/Lib/email/_header_value_parser.py Sat Apr 16 11:51:31 2016 +0000 +++ b/Lib/email/_header_value_parser.py Sat Apr 16 14:05:08 2016 +0000 @@ -1522,7 +1522,7 @@ This is not the RFC ctext, since we are handling nested comments in comment and unquoting quoted-pairs here. We allow anything except the '()' characters, but if we find any ASCII other than the RFC defined printable - ASCII an NonPrintableDefect is added to the token's defects list. Since + ASCII, a NonPrintableDefect is added to the token's defects list. Since quoted pairs are converted to their unquoted values, what is returned is a 'ptext' token. In this case it is a WhiteSpaceTerminal, so it's value is ' '. @@ -1537,7 +1537,7 @@ """qcontent = qtext / quoted-pair We allow anything except the DQUOTE character, but if we find any ASCII - other than the RFC defined printable ASCII an NonPrintableDefect is + other than the RFC defined printable ASCII, a NonPrintableDefect is added to the token's defects list. Any quoted pairs are converted to their unquoted values, so what is returned is a 'ptext' token. In this case it is a ValueTerminal. @@ -1882,7 +1882,7 @@ obs-dtext = obs-NO-WS-CTL / quoted-pair We allow anything except the excluded characters, but if we find any - ASCII other than the RFC defined printable ASCII an NonPrintableDefect is + ASCII other than the RFC defined printable ASCII, a NonPrintableDefect is added to the token's defects list. Quoted pairs are converted to their unquoted values, so what is returned is a ptext token, in this case a ValueTerminal. If there were quoted-printables, an ObsoleteHeaderDefect is diff -r ebb1a16de89b Lib/email/headerregistry.py --- a/Lib/email/headerregistry.py Sat Apr 16 11:51:31 2016 +0000 +++ b/Lib/email/headerregistry.py Sat Apr 16 14:05:08 2016 +0000 @@ -109,7 +109,7 @@ def __init__(self, display_name=None, addresses=None): """Create an object representing an address group. - An address group consists of a display_name followed by colon and an + An address group consists of a display_name followed by colon and a list of addresses (see Address) terminated by a semi-colon. The Group is created by specifying a display_name and a possibly empty list of Address objects. A Group can also be used to represent a single diff -r ebb1a16de89b Lib/lzma.py --- a/Lib/lzma.py Sat Apr 16 11:51:31 2016 +0000 +++ b/Lib/lzma.py Sat Apr 16 14:05:08 2016 +0000 @@ -279,7 +279,7 @@ constructor: LZMAFile(filename, mode, ...). In this case, the encoding, errors and newline arguments must not be provided. - For text mode, a LZMAFile object is created, and wrapped in an + For text mode, an LZMAFile object is created, and wrapped in an io.TextIOWrapper instance with the specified encoding, error handling behavior, and line ending(s). diff -r ebb1a16de89b Lib/mailbox.py --- a/Lib/mailbox.py Sat Apr 16 11:51:31 2016 +0000 +++ b/Lib/mailbox.py Sat Apr 16 14:05:08 2016 +0000 @@ -1821,7 +1821,7 @@ _type_specific_attributes = ['_labels', '_visible'] def __init__(self, message=None): - """Initialize an BabylMessage instance.""" + """Initialize a BabylMessage instance.""" self._labels = [] self._visible = Message() Message.__init__(self, message) diff -r ebb1a16de89b Lib/pprint.py --- a/Lib/pprint.py Sat Apr 16 11:51:31 2016 +0000 +++ b/Lib/pprint.py Sat Apr 16 14:05:08 2016 +0000 @@ -72,7 +72,7 @@ class _safe_key: """Helper function for key functions when sorting unorderable objects. - The wrapped-object will fallback to an Py2.x style comparison for + The wrapped-object will fallback to a Py2.x style comparison for unorderable types (sorting first comparing the type name and then by the obj ids). Does not work recursively, so dict.items() must have _safe_key applied to both the key and the value. diff -r ebb1a16de89b Lib/socket.py --- a/Lib/socket.py Sat Apr 16 11:51:31 2016 +0000 +++ b/Lib/socket.py Sat Apr 16 14:05:08 2016 +0000 @@ -685,7 +685,7 @@ global default timeout setting returned by :func:`getdefaulttimeout` is used. If *source_address* is set it must be a tuple of (host, port) for the socket to bind as a source address before making the connection. - An host of '' or port 0 tells the OS to use the default. + A host of '' or port 0 tells the OS to use the default. """ host, port = address diff -r ebb1a16de89b Lib/test/test_tools/test_gprof2html.py --- a/Lib/test/test_tools/test_gprof2html.py Sat Apr 16 11:51:31 2016 +0000 +++ b/Lib/test/test_tools/test_gprof2html.py Sat Apr 16 14:05:08 2016 +0000 @@ -22,7 +22,7 @@ sys.argv = [] def test_gprof(self): - # Issue #14508: this used to fail with an NameError. + # Issue #14508: this used to fail with a NameError. with mock.patch.object(self.gprof, 'webbrowser') as wmock, \ tempfile.TemporaryDirectory() as tmpdir: fn = os.path.join(tmpdir, 'abc') diff -r ebb1a16de89b Lib/tkinter/test/test_ttk/test_functions.py --- a/Lib/tkinter/test/test_ttk/test_functions.py Sat Apr 16 11:51:31 2016 +0000 +++ b/Lib/tkinter/test/test_ttk/test_functions.py Sat Apr 16 14:05:08 2016 +0000 @@ -193,7 +193,7 @@ ## Testing type = vsapi # vsapi type expects at least a class name and a part_id, so this - # should raise an ValueError since it tries to get two elements from + # should raise a ValueError since it tries to get two elements from # an empty tuple self.assertRaises(ValueError, ttk._format_elemcreate, 'vsapi') diff -r ebb1a16de89b Lib/tkinter/tix.py --- a/Lib/tkinter/tix.py Sat Apr 16 11:51:31 2016 +0000 +++ b/Lib/tkinter/tix.py Sat Apr 16 14:05:08 2016 +0000 @@ -221,7 +221,7 @@ self.tk.eval('package require Tix') def destroy(self): - # For safety, remove an delete_window binding before destroy + # For safety, remove and delete_window binding before destroy self.protocol("WM_DELETE_WINDOW", "") tkinter.Tk.destroy(self) diff -r ebb1a16de89b Misc/HISTORY --- a/Misc/HISTORY Sat Apr 16 11:51:31 2016 +0000 +++ b/Misc/HISTORY Sat Apr 16 14:05:08 2016 +0000 @@ -18737,7 +18737,7 @@ - xml.dom.minidom offers a toprettyxml method. A number of DOM conformance issues have been resolved. In particular, Element now - has an hasAttributes method, and the handling of namespaces was + has a hasAttributes method, and the handling of namespaces was improved. - Ka-Ping Yee contributed two new modules: inspect.py, a module for @@ -21712,7 +21712,7 @@ - The uu module now deals better with trailing garbage generated by some broke uuencoders. -- The telnet module now has an my_interact() method which uses threads +- The telnet module now has a my_interact() method which uses threads instead of select. The interact() method uses this by default on Windows (where the single-threaded version doesn't work). @@ -22769,7 +22769,7 @@ - New macros to access object members for PyFunction, PyCFunction objects. -- New APIs PyImport_AppendInittab() an PyImport_ExtendInittab() to +- New APIs PyImport_AppendInittab() and PyImport_ExtendInittab() to dynamically add one or many entries to the table of built-in modules. - New macro Py_InitModule3(name, methods, doc) which calls diff -r ebb1a16de89b Modules/_pickle.c --- a/Modules/_pickle.c Sat Apr 16 11:51:31 2016 +0000 +++ b/Modules/_pickle.c Sat Apr 16 14:05:08 2016 +0000 @@ -4465,7 +4465,7 @@ } else { PyErr_Format(PyExc_TypeError, - "'memo' attribute must be an PicklerMemoProxy object" + "'memo' attribute must be a PicklerMemoProxy object" "or dict, not %.200s", Py_TYPE(obj)->tp_name); return -1; } diff -r ebb1a16de89b Modules/_tracemalloc.c --- a/Modules/_tracemalloc.c Sat Apr 16 11:51:31 2016 +0000 +++ b/Modules/_tracemalloc.c Sat Apr 16 14:05:08 2016 +0000 @@ -719,7 +719,7 @@ the caller, because realloc() may already have shrinked the memory block and so removed bytes. - This case is very unlikely: an hash entry has just been + This case is very unlikely: a hash entry has just been released, so the hash table should have at least one free entry. The GIL and the table lock ensures that only one thread is diff -r ebb1a16de89b Modules/itertoolsmodule.c --- a/Modules/itertoolsmodule.c Sat Apr 16 11:51:31 2016 +0000 +++ b/Modules/itertoolsmodule.c Sat Apr 16 14:05:08 2016 +0000 @@ -4484,7 +4484,7 @@ PyDoc_STRVAR(zip_longest_doc, "zip_longest(iter1 [,iter2 [...]], [fillvalue=None]) --> zip_longest object\n\ \n\ -Return an zip_longest object whose .__next__() method returns a tuple where\n\ +Return a zip_longest object whose .__next__() method returns a tuple where\n\ the i-th element comes from the i-th iterable argument. The .__next__()\n\ method continues until the longest iterable in the argument sequence\n\ is exhausted and then it raises StopIteration. When the shorter iterables\n\ diff -r ebb1a16de89b Objects/rangeobject.c --- a/Objects/rangeobject.c Sat Apr 16 11:51:31 2016 +0000 +++ b/Objects/rangeobject.c Sat Apr 16 14:05:08 2016 +0000 @@ -5,7 +5,7 @@ /* Support objects whose length is > PY_SSIZE_T_MAX. - This could be sped up for small PyLongs if they fit in an Py_ssize_t. + This could be sped up for small PyLongs if they fit in a Py_ssize_t. This only matters on Win64. Though we could use PY_LONG_LONG which would presumably help perf. */ diff -r ebb1a16de89b Objects/stringlib/unicode_format.h --- a/Objects/stringlib/unicode_format.h Sat Apr 16 11:51:31 2016 +0000 +++ b/Objects/stringlib/unicode_format.h Sat Apr 16 14:05:08 2016 +0000 @@ -1226,7 +1226,7 @@ 0}; /* unicode_formatter_field_name_split is used to implement - string.Formatter.vformat. it takes an PEP 3101 "field name", and + string.Formatter.vformat. it takes a PEP 3101 "field name", and returns a tuple of (first, rest): "first", the part before the first '.' or '['; and "rest", an iterator for the rest of the field name. it's a wrapper around stringlib/string_format.h's