public static @Nullable PsiElement getFileContext(@NotNull PsiFile file) {
    SmartPsiElementPointer pointer = file.getUserData(INJECTED_IN_ELEMENT);
    return pointer == null ? null : pointer.getElement();
  }
public static @Nullable PsiElement getFileContext(@NotNull PsiFile file)