boolean (@Nullable VirtualFile file, @NotNull Project project) { if (file != null && !(file instanceof LightVirtualFile)) { final FileIndexFacade index = FileIndexFacade.getInstance(project); if (index.isInSource(file) || index.isInLibraryClasses(file)) { return true; } } return false; }