private findLeftoverUseOfDeprecatedAPIs()

in src/transforms/deprecated-remover.ts [230:251]


  private findLeftoverUseOfDeprecatedAPIs(assembly: Assembly, strippedFqns: Set<string>): readonly JsiiDiagnostic[] {
    if (assembly.types == null) {
      return [];
    }

    const result = new Array<JsiiDiagnostic>();

    for (const type of Object.values(assembly.types)) {
      if (isEnumType(type) || strippedFqns.has(type.fqn)) {
        continue;
      }
      if (isClassType(type) && type.initializer) {
        result.push(...this.verifyCallable(assembly, strippedFqns, type.initializer));
      }
      if (type.methods)
        for (const method of type.methods) result.push(...this.verifyCallable(assembly, strippedFqns, method));
      if (type.properties)
        for (const property of type.properties) result.push(...this.verifyProperty(assembly, strippedFqns, property));
    }

    return result;
  }