@RequiresReadLock
  @Nullable
  public static PsiFile getPsiFile(@Nullable XSourcePosition position, Project project) {
    if (position != null) {
      VirtualFile file = position.getFile();
      if (file.isValid()) {
        return PsiManager.getInstance(project).findFile(file);
      }
    }
    return null;
  }
@RequiresReadLock
  @Nullable
  public static PsiFile getPsiFile(@Nullable XSourcePosition position, Project project)