Skip to content

Commit f1648f5

Browse files
kianelbomiss-islington
authored andcommitted
pythongh-138871: Clarify NameError exception in 'del' (pythonGH-138881)
(cherry picked from commit 481588a) Co-authored-by: Kian Eliasi <[email protected]>
1 parent d8d11d5 commit f1648f5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Doc/reference/simple_stmts.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -463,8 +463,8 @@ Deletion of a target list recursively deletes each target, from left to right.
463463

464464
Deletion of a name removes the binding of that name from the local or global
465465
namespace, depending on whether the name occurs in a :keyword:`global` statement
466-
in the same code block. If the name is unbound, a :exc:`NameError` exception
467-
will be raised.
466+
in the same code block. Trying to delete an unbound name raises a
467+
:exc:`NameError` exception.
468468

469469
.. index:: pair: attribute; deletion
470470

0 commit comments

Comments
 (0)