code: public static List<TypeDeclaration> mergeTypes(List<TypeDeclaration> one, List<TypeDeclaration> two) throws Exception {
          List<TypeDeclaration> result = new ArrayList<>();
  
          for (TypeDeclaration outer : one) {
  
              boolean found = false;
              for (TypeDeclaration inner : two) {
  
                  if (outer.getName().equals(inner.getName())) {
                      TypeDeclaration merged = mergeType(outer, inner);
                      result.add(merged);
                      found = true;
                  }
              }
  
              if (!found) {
                  result.add(outer);
                  LOG.info("add {} --> {}", outer.getClass().getSimpleName(), outer.getName());
              }
          }
          return result;
      }
docs: /*
  合并类型声明
  @throws Exception