Skip to content

Contextual type of 'any' should be ignored #6190

Description

getContextuallyTypedParameterType should return undefined instead of any

letx: {f(a,b): any,g(): any}={f: (a="none",b)=>a.length,g: (a="none",b){ return a.length}}

For both f and g, the parameter a: any but should be a: string.

I also ran into this with implemented/inherited functions in PR #6118.

Metadata

Metadata

Labels

BugA bug in TypeScriptBy DesignDeprecated - use "Working as Intended" or "Design Limitation" instead

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions