Annotate the unexplained assignment in exception unbinding by Rosuav · Pull Request #11448 · python/cpython

@Rosuav

@Rosuav

ericvsmith

pfalcon

# body
finally:
name = None
name = None # in case name is unbound during except handling

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about going down to basics and just say in case "# body" contains "del name" ?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Even better. Maybe leave out the #.

@csabella

@Rosuav, please check the code reviews and apply the requested changes. Thanks!

@Rosuav

ericvsmith

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Thanks.