void (Collection<? super PsiReference> refs) { final V variable = ApplicationManager.getApplication().runReadAction((Computable<V>)() -> getLocalVariable()); if (variable != null) { for (PsiReference reference : ReferencesSearch.search(variable)) { ProgressManager.checkCanceled(); refs.add(reference); } } else { refs.clear(); } }