private static boolean equalLists(
      List<? extends TypeMirror> a, List<? extends TypeMirror> b, Set<ComparedElements> visiting) {
    int size = a.size();
    if (size != b.size()) {
      return false;
    }
    // Use iterators in case the Lists aren't RandomAccess
    Iterator<? extends TypeMirror> aIterator = a.iterator();
    Iterator<? extends TypeMirror> bIterator = b.iterator();
    while (aIterator.hasNext()) {
      // We checked that the lists have the same size, so we know that bIterator.hasNext() too.
      TypeMirror nextMirrorA = aIterator.next();
      TypeMirror nextMirrorB = bIterator.next();
      if (!equal(nextMirrorA, nextMirrorB, visiting)) {
        return false;
      }
    }
    return true;
  }
Returns the type of the innermost enclosing instance, or null if there is none. This is the
same as {@link DeclaredType#getEnclosingType()} except that it returns null rather than NoType
for a static type. We need this because of <a
href="https://bugs.eclipse.org/bugs/show_bug.cgi?id=508222">this bug</a> whereby the Eclipse
compiler returns a value for static classes that is not NoType.
common/src/main/java/com/google/auto/common/MoreTypes.java