changeset 43991:e3ce3731d621

ui: delete local variables instead of setting to `None` The previous code was flagged by PyCharm as an unused variable assignment. Differential Revision: https://phab.mercurial-scm.org/D7759
author Matt Harbison <matt_harbison@yahoo.com>
date Fri, 27 Dec 2019 18:51:45 -0500
parents 37458d8b0c1e
children e52a9c85a7a8
files mercurial/ui.py
diffstat 1 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/ui.py	Fri Dec 27 18:50:40 2019 -0500
+++ b/mercurial/ui.py	Fri Dec 27 18:51:45 2019 -0500
@@ -2032,7 +2032,10 @@
             self.log(
                 b'develwarn', b'%s at: %s:%d (%s)\n', msg, fname, lineno, fmsg
             )
-            curframe = calframe = None  # avoid cycles
+
+            # avoid cycles
+            del curframe
+            del calframe
 
     def deprecwarn(self, msg, version, stacklevel=2):
         """issue a deprecation warning