Deprecated since 3.6. Use trace_add() instead. This method wraps a Tcl feature that was removed in Tcl 9.0.
Register callback to be called when the variable is accessed according to mode. mode is one of the strings 'r', 'w' or 'u', for read, write or unset. Return the internal name of the registered callback. trace() is an alias of trace_variable().