Skip to content
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

Name conflicting with generic params in some cases #1684

Closed
MaxGraey opened this issue Feb 14, 2021 · 0 comments · Fixed by #2075
Closed

Name conflicting with generic params in some cases #1684

MaxGraey opened this issue Feb 14, 2021 · 0 comments · Fixed by #2075
Labels

Comments

@MaxGraey
Copy link
Member

minimal example:

function boo<T>(s: T): T { return s }
export function test(string: string): string[] {
  return boo<string>(string);
}

Error:

ERROR TS2304: Cannot find name 'string'.
    return boo<string>(string);
               ~~~~~~
@MaxGraey MaxGraey added compatibility dependencies Pull requests that update a dependency file enhancement and removed dependencies Pull requests that update a dependency file labels Feb 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants