fix(ngcc): report errors from analyze
and resolve
processing (#33964)
Previously, these errors were being swallowed, which made it hard to debug problems with packages. See https://github.com/angular/angular/issues/33685#issuecomment-557091719 PR Close #33964
This commit is contained in:

committed by
Alex Rickabaugh

parent
e53375b7b6
commit
715d02aa14
@ -212,9 +212,12 @@ export class DecorationAnalyzer {
|
||||
analyzedFile.analyzedClasses.forEach(({declaration, matches}) => {
|
||||
matches.forEach(({handler, analysis}) => {
|
||||
if ((handler.resolve !== undefined) && analysis) {
|
||||
const res = handler.resolve(declaration, analysis);
|
||||
if (res.reexports !== undefined) {
|
||||
this.addReexports(res.reexports, declaration);
|
||||
const {reexports, diagnostics} = handler.resolve(declaration, analysis);
|
||||
if (reexports !== undefined) {
|
||||
this.addReexports(reexports, declaration);
|
||||
}
|
||||
if (diagnostics !== undefined) {
|
||||
diagnostics.forEach(error => this.diagnosticHandler(error));
|
||||
}
|
||||
}
|
||||
});
|
||||
|
Reference in New Issue
Block a user