Mixin expected argument type resolves to never when constrained to constructor of type whose property is typed via a type parameter #34979
Labels
Needs Investigation
This issue needs a team member to investigate its status.
TypeScript Version: 3.8.0-dev.20191105
Search Terms: mixin 3.7 type
Code
Other Code
Or my original code... I think it's more correct to do the above, but should either of these error?
Expected behavior: No errors, as in TS < 3.7
TS 3.6.3 Playground
Actual behavior:
Playground Link: TS 3.8.0-dev.20191105 Playground
Other Comments
The issue does not occur when the type parameter is inlined (Playground).
Also, I wouldn't be surprised if I was doing something wrong here, but this has worked in the past.
Workaround
Pass the class constructor into a function typed like so and the compile error goes away (Playground):
The text was updated successfully, but these errors were encountered: