MCPcopy Index your code
hub / github.com/python/cpython / __del__

Method __del__

Lib/tkinter/__init__.py:416–425  ·  view source on GitHub ↗

Unset the variable in Tcl.

(self)

Source from the content-addressed store, hash-verified

414 self.initialize(self._default)
415
416 def __del__(self):
417 """Unset the variable in Tcl."""
418 if self._tk is None:
419 return
420 if self._tk.getboolean(self._tk.call("info", "exists", self._name)):
421 self._tk.globalunsetvar(self._name)
422 if self._tclCommands is not None:
423 for name in self._tclCommands:
424 self._tk.deletecommand(name)
425 self._tclCommands = None
426
427 def __str__(self):
428 """Return the name of the variable in Tcl."""

Callers

nothing calls this directly

Calls 3

deletecommandMethod · 0.80
getbooleanMethod · 0.45
callMethod · 0.45

Tested by

no test coverage detected