summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>2022-05-19 15:40:49 (GMT)
committerGitHub <noreply@github.com>2022-05-19 15:40:49 (GMT)
commit4d1e243fcadaeb6827343f0db16d471debb924b9 (patch)
treee78e544df9666c3bb807f8a6755d142838ed8dd9
parent54653b5005f575cb5e287b4456e01936cfe4f233 (diff)
downloadcpython-4d1e243fcadaeb6827343f0db16d471debb924b9.zip
cpython-4d1e243fcadaeb6827343f0db16d471debb924b9.tar.gz
cpython-4d1e243fcadaeb6827343f0db16d471debb924b9.tar.bz2
bpo-45393: help() on operator precedence has misleading entries (GH-31246) (GH-92965)
(cherry picked from commit fb082c2fc5a925085b179e63ca10b7f60b356d2f) Co-authored-by: Zackery Spytz <zspytz@gmail.com>
-rw-r--r--Doc/reference/expressions.rst4
-rw-r--r--Misc/NEWS.d/next/Library/2022-02-09-23-44-27.bpo-45393.9v5Y8U.rst2
2 files changed, 4 insertions, 2 deletions
diff --git a/Doc/reference/expressions.rst b/Doc/reference/expressions.rst
index b914c48..1f461e3 100644
--- a/Doc/reference/expressions.rst
+++ b/Doc/reference/expressions.rst
@@ -1898,7 +1898,7 @@ precedence and have a left-to-right chaining feature as described in the
| ``x[index]``, ``x[index:index]``, | Subscription, slicing, |
| ``x(arguments...)``, ``x.attribute`` | call, attribute reference |
+-----------------------------------------------+-------------------------------------+
-| :keyword:`await` ``x`` | Await expression |
+| :keyword:`await x <await>` | Await expression |
+-----------------------------------------------+-------------------------------------+
| ``**`` | Exponentiation [#]_ |
+-----------------------------------------------+-------------------------------------+
@@ -1922,7 +1922,7 @@ precedence and have a left-to-right chaining feature as described in the
| :keyword:`is`, :keyword:`is not`, ``<``, | tests and identity tests |
| ``<=``, ``>``, ``>=``, ``!=``, ``==`` | |
+-----------------------------------------------+-------------------------------------+
-| :keyword:`not` ``x`` | Boolean NOT |
+| :keyword:`not x <not>` | Boolean NOT |
+-----------------------------------------------+-------------------------------------+
| :keyword:`and` | Boolean AND |
+-----------------------------------------------+-------------------------------------+
diff --git a/Misc/NEWS.d/next/Library/2022-02-09-23-44-27.bpo-45393.9v5Y8U.rst b/Misc/NEWS.d/next/Library/2022-02-09-23-44-27.bpo-45393.9v5Y8U.rst
new file mode 100644
index 0000000..0a239b0
--- /dev/null
+++ b/Misc/NEWS.d/next/Library/2022-02-09-23-44-27.bpo-45393.9v5Y8U.rst
@@ -0,0 +1,2 @@
+Fix the formatting for ``await x`` and ``not x`` in the operator precedence
+table when using the :func:`help` system.