This came up while I was working on #57033. The visitor that is meant to visit every expression in a template currently skips over the templateAttrs (see). This is incorrect, because the templateAttrs don't get copied over into the element node for something like <div *ngIf="expr"></div>. As a result, our current extended diagnostics haven't been checking the expressions of structural directives. In #57033 I tried fixing it, but there were a lot of failures even for the trial run so I expect a lot more for a global one.
As a workaround in #57033, I've added a flag that allows the problematic diagnostics to retain their old behavior, but eventually we should remove the canVisitStructuralAttributes flag and resolve the failures.
This came up while I was working on #57033. The visitor that is meant to visit every expression in a template currently skips over the
templateAttrs(see). This is incorrect, because thetemplateAttrsdon't get copied over into the element node for something like<div *ngIf="expr"></div>. As a result, our current extended diagnostics haven't been checking the expressions of structural directives. In #57033 I tried fixing it, but there were a lot of failures even for the trial run so I expect a lot more for a global one.As a workaround in #57033, I've added a flag that allows the problematic diagnostics to retain their old behavior, but eventually we should remove the
canVisitStructuralAttributesflag and resolve the failures.