# Bug Report ```typescript type ApplyFn<Fn extends (item: any) => any, T> = Fn extends (item: T) => infer R ? R : never type X = ApplyFn<(x: number) => string, number> ``` type X is `string` ```typescript type Fn = <T>(item: T) => {foo: T} type Y = ApplyFn<Fn, string> ``` type Y is `{foo: unknown}` but I have expected `{foo: string}` ### 🔎 Search Terms infer generic function return type ### ⏯ Playground Link [Playground link with relevant code](https://www.typescriptlang.org/play?#code/C4TwDgpgBAgmYBsQDEB2AeNUIA9gVQBMBnKACgEt8BbALigENUQBKKAXgD5HmAaKACrd2AWABQUKFlz4ipSjXoC2XKBVQAzCACcoAJSgB+fVHqoIANx3jxoSFAAaHWPCRp0ZHGYCu1AEY6KtzEwNrqAOb8qL4B2py24NBY7FDoQgoQdIJBUADeGgD2BUoAvgn2AJrOcIgoGGj8IWGo4fFiQA) Is there any workaround to solve this problem?