private static void deQualifyImpl(PsiQualifiedReferenceElement reference) {
    PsiElement qualifier = reference.getQualifier();
    if (qualifier != null) {
      ASTNode qNode = qualifier.getNode();
      if (qNode == null) return;
      ASTNode firstChildNode = qNode.getFirstChildNode();
      boolean markToReformatBefore = firstChildNode instanceof TreeElement && CodeEditUtil.isMarkedToReformatBefore((TreeElement)firstChildNode);
      new CommentTracker().deleteAndRestoreComments(qualifier);
      if (markToReformatBefore) {
        firstChildNode = reference.getNode().getFirstChildNode();
        if (firstChildNode != null) {
          CodeEditUtil.markToReformatBefore(firstChildNode, true);
        }
      }
    }
  }
private static void deQualifyImpl(PsiQualifiedReferenceElement reference)