You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
cannot be resolved because T is a type reference and I don't think pattern stores information to resolve this. I think this means we have to count required parameters with types. I don't know if this is a big performance hit or if I'm just misunderstanding the problem. I'm going to work on a type based implementation but if my understanding is completely wrong please let me know!
The text was updated successfully, but these errors were encountered:
On second thought I'm not sure types are the right way to do this either since Type::params don't seem to store their resolved types. I think the issue is arity checks need to happen as the types are resolved for type params. Like
I think it can be handled with Type because we don't have resolved types while checking arity for first time, but we uses Type which is not Type::Param after we resolve the overload.
This code talked about in the issue is in: https://github.com/dudykr/stc/blob/main/crates/stc_ts_file_analyzer/src/analyzer/expr/call_new.rs
The current min_required_pat implementation has the clause
So the following code:
is given 1 required parameter. This is an issue that can be solved within the pattern (I think), however code that looks like
cannot be resolved because T is a type reference and I don't think pattern stores information to resolve this. I think this means we have to count required parameters with types. I don't know if this is a big performance hit or if I'm just misunderstanding the problem. I'm going to work on a type based implementation but if my understanding is completely wrong please let me know!
The text was updated successfully, but these errors were encountered: