Posted to tcl by emiliano at Thu Oct 05 14:09:09 GMT 2023view pretty

Bug is shown in https://imgur.com/a/0tLCVEr
The code fails because the namespace has a [destroy] command itself, with different signature, and since is called inside [catch] it went unnoticed.
Simple patch follows

Index: library/systray.tcl
==================================================================
--- library/systray.tcl
+++ library/systray.tcl
@@ -35,11 +35,11 @@
 								    [winfo pointerxy $w]]]} {
 	    return
 	}
 
 	set top $w._balloon
-	catch {destroy $top}
+	catch {::destroy $top}
 	toplevel $top -bg black -bd 1
 	wm overrideredirect $top 1
 	if {[tk windowingsystem] eq "aqua"}  {
 	    ::tk::unsupported::MacWindowStyle style $top help none
 	}