File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -338,12 +338,16 @@ \section{The \keyword{del} statement \label{del}}
338338Deletion of a target list recursively deletes each target, from left
339339to right.
340340
341- Deletion of a name removes the binding of that name (which must exist)
341+ Deletion of a name removes the binding of that name
342342from the local or global namespace, depending on whether the name
343- occurs in a \keyword {global} statement in the same code block.
343+ occurs in a \keyword {global} statement in the same code block. If the
344+ name is unbound, a \exception {NameError} exception will be raised.
344345\stindex {global}
345346\indexii {unbinding}{name}
346347
348+ It is illegal to delete a name from the local namespace if it occurs
349+ as a free variable\indexii {free}{varaible} in a nested block.
350+
347351Deletion of attribute references, subscriptions and slicings
348352is passed to the primary object involved; deletion of a slicing
349353is in general equivalent to assignment of an empty slice of the
You can’t perform that action at this time.
0 commit comments