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
Problem is that when we relate signatures to each other, we erase type parameters to anys.
We have a fix for that, but nowadays whenever we have a fix we also have a break.
It blows up types for styled-components/v3 blows up with an out-of-memory (OOM) error.
And it breaks Ember's Observer type (which is actually invarian) and the addObserver method whose methods take a key and a value for the current type.
The more recent styled-components increases in type-checking time.
About 2 seconds.
Now we're talking about
Slow completions
Completions have slowed down nowadays as well, partially because we check against the this type to decide whether we should even show methods in the first place.
Wesley: The problem is that we do a fully structural check, but we fundamentally need to make that cheap somehow.
One idea is that we need to be able to keep the constraint from the false branch of conditionals to short-circuit operations (by not eagerly evaluating conditionals)
Introducing negated types would be problematic for reasoning about, display purposes.
Worth trying at least.
Could also try to avoid instantiations of conditionals using infer types.
We also don't cache the results of what conditional inference does.
One other thing is we need to be able to help inform people whether their DefinitelyTyped changes are going to cause regressions so we can judge whether more accurate types are "worth it".
Perf edition!
Fix relations of instantiations of the same signature
#31029
anys.Observertype (which is actually invarian) and theaddObservermethod whose methods take a key and a value for the current type.styled-componentsincreases in type-checking time.Now we're talking about
Slow completions
thistype to decide whether we should even show methods in the first place.infertypes.Action items:
thisparameter filtering in completions. (@weswigham)Caching control flow results across invocations
#31003
Array spread emit fixes
#8856
#31166
concatand that omits missing elements.--downlevelIteration, this works right, but not otherwise.