summaryrefslogtreecommitdiffstats
path: root/Doc
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2018-05-29 09:04:55 (GMT)
committerGitHub <noreply@github.com>2018-05-29 09:04:55 (GMT)
commit73cbe7a01a22d02dbe1ec841e8779c775cad3d08 (patch)
tree0c39a8adb1cebdfc95cc991223c6c278fb13100a /Doc
parent2179022d94937d7b0600b0dc192ca6fa5f53d830 (diff)
downloadcpython-73cbe7a01a22d02dbe1ec841e8779c775cad3d08.zip
cpython-73cbe7a01a22d02dbe1ec841e8779c775cad3d08.tar.gz
cpython-73cbe7a01a22d02dbe1ec841e8779c775cad3d08.tar.bz2
bpo-32911: Revert bpo-29463. (GH-7121) (GH-7197)
Remove the docstring attribute of AST types and restore docstring expression as a first stmt in their body. Co-authored-by: INADA Naoki <methane@users.noreply.github.com>
Diffstat (limited to 'Doc')
-rw-r--r--Doc/library/ast.rst4
-rw-r--r--Doc/whatsnew/3.7.rst7
2 files changed, 0 insertions, 11 deletions
diff --git a/Doc/library/ast.rst b/Doc/library/ast.rst
index a75a6af..9ff422c 100644
--- a/Doc/library/ast.rst
+++ b/Doc/library/ast.rst
@@ -151,10 +151,6 @@ and classes for traversing abstract syntax trees:
.. versionchanged:: 3.5
:class:`AsyncFunctionDef` is now supported.
- .. versionchanged:: 3.7
- The docstring is now exported from the node docstring field, instead of
- the first body statement.
-
.. function:: fix_missing_locations(node)
diff --git a/Doc/whatsnew/3.7.rst b/Doc/whatsnew/3.7.rst
index b466e74..8b94cdc 100644
--- a/Doc/whatsnew/3.7.rst
+++ b/Doc/whatsnew/3.7.rst
@@ -2161,13 +2161,6 @@ Changes in Python Behavior
Changes in the Python API
-------------------------
-* ``Module``, ``FunctionDef``, ``AsyncFunctionDef``, and
- ``ClassDef`` AST nodes now have the new ``docstring`` attribute.
- The first statement in their body is not considered as a docstring
- anymore. ``co_firstlineno`` and ``co_lnotab`` of code object for class
- and module are affected by this change. (Contributed by INADA Naoki and
- Eugene Toder in :issue:`29463`.)
-
* :meth:`socketserver.ThreadingMixIn.server_close` now waits until all
non-daemon threads complete. Set the new
:attr:`socketserver.ThreadingMixIn.block_on_close` class attribute to