@NotNull
  private static Map<FunExprOccurrence, Confidence> filterInapplicable(@NotNull List<? extends PsiClass> samClasses,
                                                                       @NotNull VirtualFile vFile,
                                                                       @NotNull Collection<? extends FunExprOccurrence> occurrences,
                                                                       @NotNull Project project) {
    return ReadAction.nonBlocking(() -> {
      Map<FunExprOccurrence, Confidence> map = new HashMap<>();
      for (FunExprOccurrence occurrence : occurrences) {
        ThreeState result = occurrence.checkHasTypeLight(samClasses, vFile, project);
        if (result != ThreeState.NO) {
          map.put(occurrence, result == ThreeState.YES ? Confidence.sure : Confidence.needsCheck);
        }
      }
      return map;
    }).inSmartMode(project)
      .executeSynchronously();
  }
@NotNull
  private static Map<FunExprOccurrence, Confidence> filterInapplicable(@NotNull List<? extends PsiClass> samClasses,
                                                                       @NotNull VirtualFile vFile,
                                                                       @NotNull Collection<? extends FunExprOccurrence> occurrences,
                                                                       @NotNull Project project)