Skip to content

Deconstruction: Don't prematurely resolve lazy diagnostics #13828

@jcouv

Description

@jcouv

See comment

I missed this during the previous review. It might be inappropriate to use HasAnyErrors here. There are at least two reasons for that:

It resolves lazy diagnostics, which could create circularity problems in certain contexts.
Lazy errors shouldn't really fail the binding. An example would be an obsolete Deconstruct method. Yes, it is an error to use it, but that shouldn't prevent us from recording the actual binding information and continuing to the next level. I.e. we shouldn't complain that we couldn't find a suitable method.
Consider using HasAnyResolvedErrors instead and adding a test with an obsolete Deconstruct method.

Split this issue from the umbrella for deconstruction work items #11299

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions