SetDefault installs the global Tracker. Passing nil installs a no-op tracker.
(t Tracker)
| 120 | |
| 121 | // SetDefault installs the global Tracker. Passing nil installs a no-op tracker. |
| 122 | func SetDefault(t Tracker) { |
| 123 | mu.Lock() |
| 124 | defer mu.Unlock() |
| 125 | if t == nil { |
| 126 | t = noopTracker{} |
| 127 | } |
| 128 | current = t |
| 129 | } |
no outgoing calls