src/vs/workbench/contrib/audioCues/browser/observable.ts/AutorunObserver/runIfNeeded
class AutorunObserver:	private runIfNeeded(): void {
		if (!this.needsToRun) {
			return;
		}
		// Assert: this.staleDependencies is an empty set.
		const emptySet = this.staleDependencies;
		this.staleDependencies = this._dependencies;
		this._dependencies = emptySet;

		this.needsToRun = false;

		try {
			this.runFn(this);
		} finally {
			// We don't want our observed observables to think that they are (not even temporarily) not being observed.
			// Thus, we only unsubscribe from observables that are definitely not read anymore.
			for (const o of this.staleDependencies) {
				o.unsubscribe(this);
			}
			this.staleDependencies.clear();
		}
	}