private static @NlsSafe String getLocationString(PsiElement element) {
    PsiFile file = element.getContainingFile();
    return file != null ? " [" + file.getName() + "]" : "";
  }
private static @NlsSafe String getLocationString(PsiElement element)