static new Flag startDeadlockDetector_started; static int startDeadlockDetector_interval; static void startDeadlockDetector() { if (startDeadlockDetector_started.raise()) doEvery_daemon(1000, func { if (empty(printDeadlocks())) null; print("Stopping deadlock detector."); false; }); }