Skip to content

Issue a useful error when calling a function with too many arguments #6045

Description

@RyanCavanaugh
'x'.substr(1, 2, 3);

Gives you this:

error TS2346: Supplied parameters do not match any signature of call target

This is unhelpful. We should elaborate with an error about arity.

Metadata

Metadata

Assignees

Labels

BugA bug in TypeScriptFixedA PR has been merged for this issue

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions