public boolean hasUnprocessedChanges(@NotNull CompileContext context, @NotNull BuildTarget<?> target) {
    if (!myInitialScanPerformed.contains(target)) {
      return false;
    }
    final FilesDelta delta = myDeltas.get(target);
    if (delta == null) {
      return false;
    }
    final long targetBuildStart = context.getCompilationStartStamp(target);
    if (targetBuildStart <= 0L) {
      return false;
    }
    final CompileScope scope = context.getScope();
    final BuildRootIndex rootIndex = context.getProjectDescriptor().getBuildRootIndex();
    try {
      delta.lockData();
      final long now = System.currentTimeMillis();
      for (Set<File> files : delta.getSourcesToRecompile().values()) {
        files_loop:
        for (File file : files) {
          final long fileStamp;
          if (getEventRegistrationStamp(file) > targetBuildStart || (fileStamp = FSOperations.lastModified(file)) > targetBuildStart && fileStamp < now) {
            if (scope.isAffected(target, file)) {
              for (BuildRootDescriptor rd : rootIndex.findAllParentDescriptors(file, context)) {
                if (rd.isGenerated()) { // do not send notification for generated sources
                  continue files_loop;
                }
              }
              if (LOG.isDebugEnabled()) {
                LOG.debug("Unprocessed changes detected for target " + target +
                            "; file: " + file.getPath() +
                            "; targetBuildStart=" + targetBuildStart +
                            "; eventRegistrationStamp=" + getEventRegistrationStamp(file) +
                            "; lastModified=" + FSOperations.lastModified(file)
                );
              }
              return true;
            }
          }
        }
      }
    }
    finally {
      delta.unlockData();
    }
    return false;
  }
public boolean hasUnprocessedChanges(@NotNull CompileContext context, @NotNull BuildTarget<?> target)