Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
This implements checking of calls.
I ended up following Micha's original suggestion from back when the signature representation was first introduced, and flattening it to a single array of parameters. This turned out to be easier to manage, because we can represent parameters using indices into that array, and represent the bound argument types as an array of the same length.
Starred and double-starred arguments are still TODO; these won't be very useful until we have generics.
The handling of diagnostics is just hacked into
return_ty_result
, which was already inconsistent about whether it emitted diagnostics or not; now it's even more inconsistent. This should probably be addressed somehow before this lands.The new benchmark errors here surface the need for intersection support in
is_assignable_to
.Fixes #14161.
Test Plan
Added mdtests.