@Override
  public ProblemDescriptor @Nullable [] checkFile(@NotNull PsiFile file, @NotNull InspectionManager manager, boolean isOnTheFly) {
    final Language language = file.getLanguage();
    if (!acceptsLanguage(language)) return null;

    final Visitor visitor = createVisitor(manager, isOnTheFly);

    file.accept(visitor);

    return visitor.getProblems();
  }
@Override
  public ProblemDescriptor @Nullable [] checkFile(@NotNull PsiFile file, @NotNull InspectionManager manager, boolean isOnTheFly)