(original) (raw)
changeset: 104552:cef2373f31bb branch: 2.7 parent: 104535:3b22c99535d0 user: Serhiy Storchaka storchaka@gmail.com date: Wed Oct 19 16:29:10 2016 +0300 files: Doc/c-api/none.rst Doc/c-api/unicode.rst Doc/howto/descriptor.rst Doc/howto/sorting.rst Doc/library/argparse.rst Doc/library/asyncore.rst Doc/library/bdb.rst Doc/library/collections.rst Doc/library/doctest.rst Doc/library/ensurepip.rst Doc/library/formatter.rst Doc/library/imaplib.rst Doc/library/inspect.rst Doc/library/json.rst Doc/library/logging.handlers.rst Doc/library/logging.rst Doc/library/multiprocessing.rst Doc/library/optparse.rst Doc/library/queue.rst Doc/library/select.rst Doc/library/sqlite3.rst Doc/library/ssl.rst Doc/library/string.rst Doc/library/ttk.rst Doc/library/turtle.rst Doc/library/unittest.rst Doc/library/xml.etree.elementtree.rst Doc/library/xml.sax.reader.rst Doc/reference/datamodel.rst description: Issue #19795: Mark up None as literal text. diff -r 3b22c99535d0 -r cef2373f31bb Doc/c-api/none.rst --- a/Doc/c-api/none.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/c-api/none.rst Wed Oct 19 16:29:10 2016 +0300 @@ -2,8 +2,8 @@ .. _noneobject: -The None Object ---------------- +The ``None`` Object +------------------- .. index:: object: None diff -r 3b22c99535d0 -r cef2373f31bb Doc/c-api/unicode.rst --- a/Doc/c-api/unicode.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/c-api/unicode.rst Wed Oct 19 16:29:10 2016 +0300 @@ -856,11 +856,11 @@ decode characters. Decoding mappings must map single string characters to single Unicode -characters, integers (which are then interpreted as Unicode ordinals) or None +characters, integers (which are then interpreted as Unicode ordinals) or ``None`` (meaning "undefined mapping" and causing an error). Encoding mappings must map single Unicode characters to single string -characters, integers (which are then interpreted as Latin-1 ordinals) or None +characters, integers (which are then interpreted as Latin-1 ordinals) or ``None`` (meaning "undefined mapping" and causing an error). The mapping objects provided must only support the __getitem__ mapping @@ -917,7 +917,7 @@ *NULL* when an exception was raised by the codec. The *mapping* table must map Unicode ordinal integers to Unicode ordinal - integers or None (causing deletion of the character). + integers or ``None`` (causing deletion of the character). Mapping tables need only provide the :meth:`__getitem__` interface; dictionaries and sequences work well. Unmapped character ordinals (ones which cause a @@ -1019,7 +1019,7 @@ resulting Unicode object. The mapping table must map Unicode ordinal integers to Unicode ordinal integers - or None (causing deletion of the character). + or ``None`` (causing deletion of the character). Mapping tables need only provide the :meth:`__getitem__` interface; dictionaries and sequences work well. Unmapped character ordinals (ones which cause a diff -r 3b22c99535d0 -r cef2373f31bb Doc/howto/descriptor.rst --- a/Doc/howto/descriptor.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/howto/descriptor.rst Wed Oct 19 16:29:10 2016 +0300 @@ -308,7 +308,7 @@ While they could have been implemented that way, the actual C implementation of :c:type:`PyMethod_Type` in :source:`Objects/classobject.c` is a single object with two different representations depending on whether the :attr:`im_self` -field is set or is *NULL* (the C equivalent of *None*). +field is set or is *NULL* (the C equivalent of ``None``). Likewise, the effects of calling a method object depend on the :attr:`im_self` field. If set (meaning bound), the original function (stored in the diff -r 3b22c99535d0 -r cef2373f31bb Doc/howto/sorting.rst --- a/Doc/howto/sorting.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/howto/sorting.rst Wed Oct 19 16:29:10 2016 +0300 @@ -24,7 +24,7 @@ [1, 2, 3, 4, 5] You can also use the :meth:`list.sort` method of a list. It modifies the list -in-place (and returns *None* to avoid confusion). Usually it's less convenient +in-place (and returns ``None`` to avoid confusion). Usually it's less convenient than :func:`sorted` - but if you don't need the original list, it's slightly more efficient. diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/argparse.rst --- a/Doc/library/argparse.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/argparse.rst Wed Oct 19 16:29:10 2016 +0300 @@ -1500,7 +1500,7 @@ positional arguments * description - description for the sub-parser group in help output, by - default None + default ``None`` * prog - usage information that will be displayed with sub-command help, by default the name of the program and any positional arguments before the @@ -1513,12 +1513,12 @@ encountered at the command line * dest_ - name of the attribute under which sub-command name will be - stored; by default None and no value is stored + stored; by default ``None`` and no value is stored - * help_ - help for sub-parser group in help output, by default None + * help_ - help for sub-parser group in help output, by default ``None`` * metavar_ - string presenting available sub-commands in help; by default it - is None and presents sub-commands in form {cmd1, cmd2, ..} + is ``None`` and presents sub-commands in form {cmd1, cmd2, ..} Some example usage:: diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/asyncore.rst --- a/Doc/library/asyncore.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/asyncore.rst Wed Oct 19 16:29:10 2016 +0300 @@ -51,7 +51,7 @@ Enter a polling loop that terminates after count passes or all open channels have been closed. All arguments are optional. The *count* - parameter defaults to None, resulting in the loop terminating only when all + parameter defaults to ``None``, resulting in the loop terminating only when all channels have been closed. The *timeout* argument sets the timeout parameter for the appropriate :func:`~select.select` or :func:`~select.poll` call, measured in seconds; the default is 30 seconds. The *use_poll* diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/bdb.rst --- a/Doc/library/bdb.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/bdb.rst Wed Oct 19 16:29:10 2016 +0300 @@ -233,7 +233,7 @@ .. method:: set_continue() Stop only at breakpoints or when finished. If there are no breakpoints, - set the system trace function to None. + set the system trace function to ``None``. .. method:: set_quit() diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/collections.rst --- a/Doc/library/collections.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/collections.rst Wed Oct 19 16:29:10 2016 +0300 @@ -237,7 +237,7 @@ .. versionadded:: 2.4 - If *maxlen* is not specified or is *None*, deques may grow to an + If *maxlen* is not specified or is ``None``, deques may grow to an arbitrary length. Otherwise, the deque is bounded to the specified maximum length. Once a bounded length deque is full, when new items are added, a corresponding number of items are discarded from the opposite end. Bounded @@ -321,7 +321,7 @@ .. attribute:: maxlen - Maximum size of a deque or *None* if unbounded. + Maximum size of a deque or ``None`` if unbounded. .. versionadded:: 2.7 diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/doctest.rst --- a/Doc/library/doctest.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/doctest.rst Wed Oct 19 16:29:10 2016 +0300 @@ -1273,7 +1273,7 @@ .. attribute:: docstring - The string that the test was extracted from, or 'None' if the string is + The string that the test was extracted from, or ``None`` if the string is unavailable, or if the test was not extracted from a string. @@ -1381,7 +1381,7 @@ not specified, then ``obj.__name__`` is used. The optional parameter *module* is the module that contains the given object. - If the module is not specified or is None, then the test finder will attempt + If the module is not specified or is ``None``, then the test finder will attempt to automatically determine the correct module. The object's module is used: * As a default namespace, if *globs* is not specified. diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/ensurepip.rst --- a/Doc/library/ensurepip.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/ensurepip.rst Wed Oct 19 16:29:10 2016 +0300 @@ -94,7 +94,7 @@ Bootstraps ``pip`` into the current or designated environment. *root* specifies an alternative root directory to install relative to. - If *root* is None, then installation uses the default install location + If *root* is ``None``, then installation uses the default install location for the current environment. *upgrade* indicates whether or not to upgrade an existing installation diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/formatter.rst --- a/Doc/library/formatter.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/formatter.rst Wed Oct 19 16:29:10 2016 +0300 @@ -344,7 +344,7 @@ .. class:: DumbWriter(file=None, maxcol=72) Simple writer class which writes output on the file object passed in as *file* - or, if *file* is None, on standard output. The output is simply word-wrapped + or, if *file* is ``None``, on standard output. The output is simply word-wrapped to the number of columns specified by *maxcol*. This class is suitable for reflowing a sequence of paragraphs. diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/imaplib.rst --- a/Doc/library/imaplib.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/imaplib.rst Wed Oct 19 16:29:10 2016 +0300 @@ -90,7 +90,7 @@ Parse an IMAP4 ``INTERNALDATE`` string and return corresponding local time. The return value is a :class:`time.struct_time` instance or - None if the string has wrong format. + ``None`` if the string has wrong format. .. function:: Int2AP(num) diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/inspect.rst --- a/Doc/library/inspect.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/inspect.rst Wed Oct 19 16:29:10 2016 +0300 @@ -95,8 +95,9 @@ | | gi_code | code object | | +-----------+-----------------+---------------------------+-------+ | | gi_frame | frame object or possibly | | -| | | None once the generator | | -| | | has been exhausted | | +| | | ``None`` once the | | +| | | generator has been | | +| | | exhausted | | +-----------+-----------------+---------------------------+-------+ | | gi_running | set to 1 when generator | | | | | is executing, 0 otherwise | | @@ -478,7 +479,7 @@ four things is returned: ``(args, varargs, keywords, defaults)``. *args* is a list of the argument names (it may contain nested lists). *varargs* and *keywords* are the names of the ``*`` and ``**`` arguments or - ``None``. *defaults* is a tuple of default argument values or None if there + ``None``. *defaults* is a tuple of default argument values or ``None`` if there are no default arguments; if this tuple has *n* elements, they correspond to the last *n* elements listed in *args*. diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/json.rst --- a/Doc/library/json.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/json.rst Wed Oct 19 16:29:10 2016 +0300 @@ -403,7 +403,7 @@ (to raise :exc:`TypeError`). If *skipkeys* is false (the default), then it is a :exc:`TypeError` to - attempt encoding of keys that are not str, int, long, float or None. If + attempt encoding of keys that are not str, int, long, float or ``None``. If *skipkeys* is true, such items are simply skipped. If *ensure_ascii* is true (the default), all non-ASCII characters in the diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/logging.handlers.rst --- a/Doc/library/logging.handlers.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/logging.handlers.rst Wed Oct 19 16:29:10 2016 +0300 @@ -74,7 +74,7 @@ Returns a new instance of the :class:`FileHandler` class. The specified file is opened and used as the stream for logging. If *mode* is not specified, - :const:`'a'` is used. If *encoding* is not *None*, it is used to open the file + :const:`'a'` is used. If *encoding* is not ``None``, it is used to open the file with that encoding. If *delay* is true, then file opening is deferred until the first call to :meth:`emit`. By default, the file grows indefinitely. @@ -154,7 +154,7 @@ Returns a new instance of the :class:`WatchedFileHandler` class. The specified file is opened and used as the stream for logging. If *mode* is not specified, - :const:`'a'` is used. If *encoding* is not *None*, it is used to open the file + :const:`'a'` is used. If *encoding* is not ``None``, it is used to open the file with that encoding. If *delay* is true, then file opening is deferred until the first call to :meth:`emit`. By default, the file grows indefinitely. @@ -178,7 +178,7 @@ Returns a new instance of the :class:`RotatingFileHandler` class. The specified file is opened and used as the stream for logging. If *mode* is not specified, - ``'a'`` is used. If *encoding* is not *None*, it is used to open the file + ``'a'`` is used. If *encoding* is not ``None``, it is used to open the file with that encoding. If *delay* is true, then file opening is deferred until the first call to :meth:`emit`. By default, the file grows indefinitely. diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/logging.rst --- a/Doc/library/logging.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/logging.rst Wed Oct 19 16:29:10 2016 +0300 @@ -588,7 +588,7 @@ :param args: Variable data to merge into the *msg* argument to obtain the event description. :param exc_info: An exception tuple with the current exception information, - or *None* if no exception information is available. + or ``None`` if no exception information is available. :param func: The name of the function or method from which the logging call was invoked. @@ -636,7 +636,7 @@ | | | (as returned by :func:`time.time`). | +----------------+-------------------------+-----------------------------------------------+ | exc_info | You shouldn't need to | Exception tuple (à la ``sys.exc_info``) or, | -| | format this yourself. | if no exception has occurred, *None*. | +| | format this yourself. | if no exception has occurred, ``None``. | +----------------+-------------------------+-----------------------------------------------+ | filename | ``%(filename)s`` | Filename portion of ``pathname``. | +----------------+-------------------------+-----------------------------------------------+ @@ -1026,4 +1026,14 @@ package available from this site is suitable for use with Python 1.5.2, 2.1.x and 2.2.x, which do not include the :mod:`logging` package in the standard library. +<<<<<<< +======= + :lno: The line number in the file where the logging call was made. + :msg: The logging message. + :args: The arguments for the logging message. + :exc_info: An exception tuple, or ``None``. + :func: The name of the function or method which invoked the logging + call. + :sinfo: A stack traceback such as is provided by +>>>>>>> diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/multiprocessing.rst --- a/Doc/library/multiprocessing.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/multiprocessing.rst Wed Oct 19 16:29:10 2016 +0300 @@ -1800,7 +1800,7 @@ .. versionadded:: 2.7 *maxtasksperchild* is the number of tasks a worker process can complete before it will exit and be replaced with a fresh worker process, to enable - unused resources to be freed. The default *maxtasksperchild* is None, which + unused resources to be freed. The default *maxtasksperchild* is ``None``, which means worker processes will live as long as the pool. .. note:: @@ -2017,7 +2017,7 @@ ``None`` then digest authentication is used. If *authkey* is a string then it will be used as the authentication key; - otherwise it must be *None*. + otherwise it must be ``None``. If *authkey* is ``None`` and *authenticate* is ``True`` then ``current_process().authkey`` is used as the authentication key. If diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/optparse.rst --- a/Doc/library/optparse.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/optparse.rst Wed Oct 19 16:29:10 2016 +0300 @@ -2028,12 +2028,12 @@ values.ensure_value(attr, value) - If the ``attr`` attribute of ``values`` doesn't exist or is None, then + If the ``attr`` attribute of ``values`` doesn't exist or is ``None``, then ensure_value() first sets it to ``value``, and then returns 'value. This is very handy for actions like ``"extend"``, ``"append"``, and ``"count"``, all of which accumulate data in a variable and expect that variable to be of a certain type (a list for the first two, an integer for the latter). Using :meth:`ensure_value` means that scripts using your action don't have to worry about setting a default value for the option destinations in question; they - can just leave the default as None and :meth:`ensure_value` will take care of + can just leave the default as ``None`` and :meth:`ensure_value` will take care of getting it right when it's needed. diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/queue.rst --- a/Doc/library/queue.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/queue.rst Wed Oct 19 16:29:10 2016 +0300 @@ -113,7 +113,7 @@ .. method:: Queue.put(item[, block[, timeout]]) Put *item* into the queue. If optional args *block* is true and *timeout* is - None (the default), block if necessary until a free slot is available. If + ``None`` (the default), block if necessary until a free slot is available. If *timeout* is a positive number, it blocks at most *timeout* seconds and raises the :exc:`Full` exception if no free slot was available within that time. Otherwise (*block* is false), put an item on the queue if a free slot is @@ -132,7 +132,7 @@ .. method:: Queue.get([block[, timeout]]) Remove and return an item from the queue. If optional args *block* is true and - *timeout* is None (the default), block if necessary until an item is available. + *timeout* is ``None`` (the default), block if necessary until an item is available. If *timeout* is a positive number, it blocks at most *timeout* seconds and raises the :exc:`Empty` exception if no item was available within that time. Otherwise (*block* is false), return an item if one is immediately available, diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/select.rst --- a/Doc/library/select.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/select.rst Wed Oct 19 16:29:10 2016 +0300 @@ -295,7 +295,7 @@ Low level interface to kevent - - changelist must be an iterable of kevent object or None + - changelist must be an iterable of kevent object or ``None`` - max_events must be 0 or a positive integer - timeout in seconds (floats possible) diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/sqlite3.rst --- a/Doc/library/sqlite3.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/sqlite3.rst Wed Oct 19 16:29:10 2016 +0300 @@ -308,7 +308,7 @@ as the SQL function. The function can return any of the types supported by SQLite: unicode, str, int, - long, float, buffer and None. + long, float, buffer and ``None``. Example: @@ -324,7 +324,7 @@ final result of the aggregate. The ``finalize`` method can return any of the types supported by SQLite: - unicode, str, int, long, float, buffer and None. + unicode, str, int, long, float, buffer and ``None``. Example: @@ -346,7 +346,7 @@ .. literalinclude:: ../includes/sqlite3/collation_reverse.py - To remove a collation, call ``create_collation`` with None as callable:: + To remove a collation, call ``create_collation`` with ``None`` as callable:: con.create_collation("reverse", None) @@ -868,7 +868,7 @@ (or none at all) via the *isolation_level* parameter to the :func:`connect` call, or via the :attr:`isolation_level` property of connections. -If you want **autocommit mode**, then set :attr:`isolation_level` to None. +If you want **autocommit mode**, then set :attr:`isolation_level` to ``None``. Otherwise leave it at its default, which will result in a plain "BEGIN" statement, or set it to one of SQLite's supported isolation levels: "DEFERRED", diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/ssl.rst --- a/Doc/library/ssl.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/ssl.rst Wed Oct 19 16:29:10 2016 +0300 @@ -449,8 +449,8 @@ :meth:`SSLContext.set_default_verify_paths`. The return value is a :term:`named tuple` ``DefaultVerifyPaths``: - * :attr:`cafile` - resolved path to cafile or None if the file doesn't exist, - * :attr:`capath` - resolved path to capath or None if the directory doesn't exist, + * :attr:`cafile` - resolved path to cafile or ``None`` if the file doesn't exist, + * :attr:`capath` - resolved path to capath or ``None`` if the directory doesn't exist, * :attr:`openssl_cafile_env` - OpenSSL's environment key that points to a cafile, * :attr:`openssl_cafile` - hard coded path to a cafile, * :attr:`openssl_capath_env` - OpenSSL's environment key that points to a capath, diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/string.rst --- a/Doc/library/string.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/string.rst Wed Oct 19 16:29:10 2016 +0300 @@ -448,7 +448,7 @@ In addition to the above presentation types, integers can be formatted with the floating point presentation types listed below (except -``'n'`` and None). When doing so, :func:`float` is used to convert the +``'n'`` and ``None``). When doing so, :func:`float` is used to convert the integer to a floating point number before formatting. The available presentation types for floating point and decimal values are: diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/ttk.rst --- a/Doc/library/ttk.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/ttk.rst Wed Oct 19 16:29:10 2016 +0300 @@ -1380,7 +1380,7 @@ Layouts ^^^^^^^ -A layout can be just None, if it takes no options, or a dict of +A layout can be just ``None``, if it takes no options, or a dict of options specifying how to arrange the element. The layout mechanism uses a simplified version of the pack geometry manager: given an initial cavity, each element is allocated a parcel. Valid diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/turtle.rst --- a/Doc/library/turtle.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/turtle.rst Wed Oct 19 16:29:10 2016 +0300 @@ -529,7 +529,7 @@ :param n: an integer (or ``None``) - Delete all or first/last *n* of turtle's stamps. If *n* is None, delete + Delete all or first/last *n* of turtle's stamps. If *n* is ``None``, delete all stamps, if *n* > 0 delete first *n* stamps, else if *n* < 0 delete last *n* stamps. @@ -1857,10 +1857,10 @@ :param height: if an integer, the height in pixels, if a float, a fraction of the screen; default is 75% of screen :param startx: if positive, starting position in pixels from the left - edge of the screen, if negative from the right edge, if None, + edge of the screen, if negative from the right edge, if ``None``, center window horizontally :param starty: if positive, starting position in pixels from the top - edge of the screen, if negative from the bottom edge, if None, + edge of the screen, if negative from the bottom edge, if ``None``, center window vertically .. doctest:: diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/unittest.rst --- a/Doc/library/unittest.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/unittest.rst Wed Oct 19 16:29:10 2016 +0300 @@ -878,7 +878,7 @@ .. method:: assertIsNone(expr, msg=None) assertIsNotNone(expr, msg=None) - Test that *expr* is (or is not) None. + Test that *expr* is (or is not) ``None``. .. versionadded:: 2.7 @@ -1240,7 +1240,7 @@ methods that delegate to it), :meth:`assertDictEqual` and :meth:`assertMultiLineEqual`. - Setting ``maxDiff`` to None means that there is no maximum length of + Setting ``maxDiff`` to ``None`` means that there is no maximum length of diffs. .. versionadded:: 2.7 diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/xml.etree.elementtree.rst --- a/Doc/library/xml.etree.elementtree.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/xml.etree.elementtree.rst Wed Oct 19 16:29:10 2016 +0300 @@ -639,7 +639,7 @@ .. method:: clear() Resets an element. This function removes all subelements, clears all - attributes, and sets the text and tail attributes to None. + attributes, and sets the text and tail attributes to ``None``. .. method:: get(key, default=None) @@ -855,8 +855,8 @@ Writes the element tree to a file, as XML. *file* is a file name, or a file object opened for writing. *encoding* [1]_ is the output encoding (default is US-ASCII). *xml_declaration* controls if an XML declaration - should be added to the file. Use False for never, True for always, None - for only if not US-ASCII or UTF-8 (default is None). *default_namespace* + should be added to the file. Use False for never, True for always, ``None`` + for only if not US-ASCII or UTF-8 (default is ``None``). *default_namespace* sets the default XML namespace (for "xmlns"). *method* is either ``"xml"``, ``"html"`` or ``"text"`` (default is ``"xml"``). Returns an encoded string. diff -r 3b22c99535d0 -r cef2373f31bb Doc/library/xml.sax.reader.rst --- a/Doc/library/xml.sax.reader.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/library/xml.sax.reader.rst Wed Oct 19 16:29:10 2016 +0300 @@ -306,7 +306,7 @@ Get the byte stream for this input source. The getEncoding method will return the character encoding for this byte stream, - or None if unknown. + or ``None`` if unknown. .. method:: InputSource.setCharacterStream(charfile) diff -r 3b22c99535d0 -r cef2373f31bb Doc/reference/datamodel.rst --- a/Doc/reference/datamodel.rst Sun Oct 16 19:14:23 2016 +0200 +++ b/Doc/reference/datamodel.rst Wed Oct 19 16:29:10 2016 +0300 @@ -830,7 +830,7 @@ dictionary containing the class's namespace; :attr:`~class.__bases__` is a tuple (possibly empty or a singleton) containing the base classes, in the order of their occurrence in the base class list; :attr:`__doc__` is the - class's documentation string, or None if undefined. + class's documentation string, or ``None`` if undefined. Class instances .. index:: @@ -1013,7 +1013,7 @@ called at the start of each source code line (this is used by the debugger); :attr:`f_exc_type`, :attr:`f_exc_value`, :attr:`f_exc_traceback` represent the last exception raised in the parent frame provided another exception was ever - raised in the current frame (in all other cases they are None); :attr:`f_lineno` + raised in the current frame (in all other cases they are ``None``); :attr:`f_lineno` is the current line number of the frame --- writing to this from within a trace function jumps to the given line (only for the bottom-most frame). A debugger can implement a Jump command (aka Set Next Statement) by writing to f_lineno. /storchaka@gmail.com