code: @SuppressWarnings("unchecked")
    public static ImmutableList<Element> getEnclosedElements(Element element) {
      return (ImmutableList<Element>) enclosedBy(element).immutableSortedCopy(element.getEnclosedElements());
    }
docs: it's safe to cast immutable list of <? extends Element> to a list of <Element>