docs: public static boolean checkCloseTagClosesOptional(TagName closeTag, TagName optionalOpenTag) {
      // TODO(b/120994894): Replace this with checkArgument() when HtmlTagEntry can be replaced.
      if (!optionalOpenTag.isStatic() || !optionalOpenTag.isDefinitelyOptional()) {
        return false;
      }
      if (!closeTag.isStatic()) {
        return true;
      }
      String openTagName = optionalOpenTag.getStaticTagNameAsLowerCase();
      String closeTagName = closeTag.getStaticTagNameAsLowerCase();
      checkArgument(!openTagName.equals(closeTagName));
      if ("p".equals(openTagName)) {
        return !PTAG_CLOSE_EXCEPTIONS.contains(closeTagName);
      }
      return OPTIONAL_TAG_CLOSE_TAG_RULES.containsEntry(openTagName, closeTagName);
    }