[Python-checkins] bpo-38605: Update "Future statements" docs since PEP 563 is always enabled (GH-25236)
miss-islington
webhook-mailer at python.org
Wed Apr 7 01:02:28 EDT 2021
https://github.com/python/cpython/commit/1be456ae9d53bb1cba2b24fc86175c282d1c2169
commit: 1be456ae9d53bb1cba2b24fc86175c282d1c2169
branch: master
author: Saiyang Gou <gousaiyang at 163.com>
committer: miss-islington <31488909+miss-islington at users.noreply.github.com>
date: 2021-04-06T22:02:20-07:00
summary:
bpo-38605: Update "Future statements" docs since PEP 563 is always enabled (GH-25236)
Update documentation section for "Future statements" to reflect that `from __future__ import annotations` is on by default, and no features require using the future statement now.
files:
M Doc/reference/simple_stmts.rst
diff --git a/Doc/reference/simple_stmts.rst b/Doc/reference/simple_stmts.rst
index 2c6c90140201c..3fff8484856ab 100644
--- a/Doc/reference/simple_stmts.rst
+++ b/Doc/reference/simple_stmts.rst
@@ -874,14 +874,11 @@ can appear before a future statement are:
* blank lines, and
* other future statements.
-The only feature that requires using the future statement is
-``annotations`` (see :pep:`563`).
-
All historical features enabled by the future statement are still recognized
by Python 3. The list includes ``absolute_import``, ``division``,
``generators``, ``generator_stop``, ``unicode_literals``,
-``print_function``, ``nested_scopes`` and ``with_statement``. They are
-all redundant because they are always enabled, and only kept for
+``print_function``, ``nested_scopes``, ``with_statement`` and ``annotations``.
+They are all redundant because they are always enabled, and only kept for
backwards compatibility.
A future statement is recognized and treated specially at compile time: Changes
More information about the Python-checkins
mailing list