| 27 | } |
| 28 | |
| 29 | type baseSharedVariable struct { |
| 30 | // updatedAtUnixMs tracks the last-known update timestamp for this shared variable. |
| 31 | // It is used for staleness checks (TryUpdateIfStale debouncing). |
| 32 | // |
| 33 | // Semantics: unix milliseconds, monotonic increasing within a process. |
| 34 | updatedAtUnixMs atomic.Int64 |
| 35 | } |
| 36 | |
| 37 | func (v *baseSharedVariable) IsStale(staleness time.Duration) bool { |
| 38 | updatedAt := v.updatedAtUnixMs.Load() |
nothing calls this directly
no outgoing calls
no test coverage detected