bpo-35506: Remove redundant and incorrect links from keywords. (GH-11174)
diff --git a/Doc/tutorial/controlflow.rst b/Doc/tutorial/controlflow.rst
index bf6fbe2..08eaa66 100644
--- a/Doc/tutorial/controlflow.rst
+++ b/Doc/tutorial/controlflow.rst
@@ -10,8 +10,8 @@
.. _tut-if:
-:keyword:`if` Statements
-========================
+:keyword:`!if` Statements
+=========================
Perhaps the most well-known statement type is the :keyword:`if` statement. For
example::
@@ -31,16 +31,16 @@
More
There can be zero or more :keyword:`elif` parts, and the :keyword:`else` part is
-optional. The keyword ':keyword:`elif`' is short for 'else if', and is useful
-to avoid excessive indentation. An :keyword:`if` ... :keyword:`elif` ...
-:keyword:`elif` ... sequence is a substitute for the ``switch`` or
+optional. The keyword ':keyword:`!elif`' is short for 'else if', and is useful
+to avoid excessive indentation. An :keyword:`!if` ... :keyword:`!elif` ...
+:keyword:`!elif` ... sequence is a substitute for the ``switch`` or
``case`` statements found in other languages.
.. _tut-for:
-:keyword:`for` Statements
-=========================
+:keyword:`!for` Statements
+==========================
.. index::
statement: for
@@ -48,7 +48,7 @@
The :keyword:`for` statement in Python differs a bit from what you may be used
to in C or Pascal. Rather than always iterating over an arithmetic progression
of numbers (like in Pascal), or giving the user the ability to define both the
-iteration step and halting condition (as C), Python's :keyword:`for` statement
+iteration step and halting condition (as C), Python's :keyword:`!for` statement
iterates over the items of any sequence (a list or a string), in the order that
they appear in the sequence. For example (no pun intended):
@@ -154,13 +154,13 @@
.. _tut-break:
-:keyword:`break` and :keyword:`continue` Statements, and :keyword:`else` Clauses on Loops
-=========================================================================================
+:keyword:`!break` and :keyword:`!continue` Statements, and :keyword:`!else` Clauses on Loops
+============================================================================================
The :keyword:`break` statement, like in C, breaks out of the innermost enclosing
:keyword:`for` or :keyword:`while` loop.
-Loop statements may have an ``else`` clause; it is executed when the loop
+Loop statements may have an :keyword:`!else` clause; it is executed when the loop
terminates through exhaustion of the list (with :keyword:`for`) or when the
condition becomes false (with :keyword:`while`), but not when the loop is
terminated by a :keyword:`break` statement. This is exemplified by the
@@ -189,9 +189,9 @@
When used with a loop, the ``else`` clause has more in common with the
``else`` clause of a :keyword:`try` statement than it does that of
-:keyword:`if` statements: a :keyword:`try` statement's ``else`` clause runs
+:keyword:`if` statements: a :keyword:`!try` statement's ``else`` clause runs
when no exception occurs, and a loop's ``else`` clause runs when no ``break``
-occurs. For more on the :keyword:`try` statement and exceptions, see
+occurs. For more on the :keyword:`!try` statement and exceptions, see
:ref:`tut-handling`.
The :keyword:`continue` statement, also borrowed from C, continues with the next
@@ -213,8 +213,8 @@
.. _tut-pass:
-:keyword:`pass` Statements
-==========================
+:keyword:`!pass` Statements
+===========================
The :keyword:`pass` statement does nothing. It can be used when a statement is
required syntactically but the program requires no action. For example::
@@ -231,7 +231,7 @@
Another place :keyword:`pass` can be used is as a place-holder for a function or
conditional body when you are working on new code, allowing you to keep thinking
-at a more abstract level. The :keyword:`pass` is silently ignored::
+at a more abstract level. The :keyword:`!pass` is silently ignored::
>>> def initlog(*args):
... pass # Remember to implement this!
@@ -331,7 +331,7 @@
This example, as usual, demonstrates some new Python features:
* The :keyword:`return` statement returns with a value from a function.
- :keyword:`return` without an expression argument returns ``None``. Falling off
+ :keyword:`!return` without an expression argument returns ``None``. Falling off
the end of a function also returns ``None``.
* The statement ``result.append(a)`` calls a *method* of the list object