private static void checkReferenceList(@NotNull AnnotationHolder holder,
                                         @NotNull GrReferenceList list,
                                         @NotNull Condition<? super PsiClass> applicabilityCondition,
                                         @NotNull @InspectionMessage String message,
                                         @Nullable IntentionAction fix) {
    for (GrCodeReferenceElement refElement : list.getReferenceElementsGroovy()) {
      final PsiElement psiClass = refElement.resolve();
      if (psiClass instanceof PsiClass && !applicabilityCondition.value((PsiClass)psiClass)) {
        AnnotationBuilder builder = holder.newAnnotation(HighlightSeverity.ERROR, message).range(refElement);
        if (fix != null) {
          builder = builder.withFix(fix);
        }
        builder.create();
      }
    }
  }
private static void checkReferenceList(@NotNull AnnotationHolder holder,
                                         @NotNull GrReferenceList list,
                                         @NotNull Condition<? super PsiClass> applicabilityCondition,
                                         @NotNull @InspectionMessage String message,
                                         @Nullable IntentionAction fix)