docs: private static void checkBlockEndContext(RenderUnitNode node, Context endContext) {
      if (!endContext.isValidEndContextForContentKind(
          MoreObjects.firstNonNull(node.getContentKind(), SanitizedContentKind.HTML))) {
        String msg =
            String.format(
                "A block of kind=\"%s\" cannot end in context %s. Likely cause is %s.",
                node.getContentKind().asAttributeValue(),
                endContext,
                endContext.getLikelyEndContextMismatchCause(node.getContentKind()));
        throw SoyAutoescapeException.createWithNode(msg, node);
      }
    }