-
Notifications
You must be signed in to change notification settings - Fork 12.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support nested type parameters #214
Labels
Milestone
Comments
I don't really understand this one, in the following example : interface InterfaceA<U> {}
declare function myFunc<U extends InterfaceA<any>>(value: U): U ;
var b: InterfaceA<string>;
var c = myFunc(b); c is correctly typed to did you mean something like that ? : interface InterfaceA<U> {}
declare function myFunc<V, U extends InterfaceA<V>>(value: U): V; |
I would expect so, this is something I would want too. |
Fixed by #5949 |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
E.g. you cannot have an interface and function which satisfy the types:
This means you cannot make generic functions to handle derived types unless you are willing to lose the type information for the return value.
The text was updated successfully, but these errors were encountered: