@Override
  public void handleInsert(@NotNull InsertionContext context) {
    TailType tailType = computeTailType(context);

    getDelegate().handleInsert(context);
    if (tailType != null && tailType.isApplicable(context)) {
      PsiDocumentManager.getInstance(context.getProject()).doPostponedOperationsAndUnblockDocument(context.getDocument());
      int tailOffset = context.getTailOffset();
      if (tailOffset < 0) {
        throw new AssertionError("tailOffset < 0: delegate=" + getDelegate() + "; this=" + this + "; tail=" + tailType);
      }
      tailType.processTail(context.getEditor(), tailOffset);
    }
  }
@Override
  public void handleInsert(@NotNull InsertionContext context)