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

Unpacked tuples do not satisfy function argument type signature #14567

Closed
akdor1154 opened this issue Mar 9, 2017 · 1 comment
Closed

Unpacked tuples do not satisfy function argument type signature #14567

akdor1154 opened this issue Mar 9, 2017 · 1 comment
Labels
Duplicate An existing issue was already created

Comments

@akdor1154
Copy link

TypeScript Version: 2.2.1

Code

function testUnpack(s: string, n: number) {
	return true;
}

const testArgs: [string, number] = ['asdf', 123];

testUnpack(...testArgs);

Expected behavior:
compiles with no issue
Actual behavior:
error TS2346: Supplied parameters do not match any signature of call target.

@akdor1154
Copy link
Author

sorry, dupe of #5296
(I am apparently in Python mode, and searched for unpack not spread)

@RyanCavanaugh RyanCavanaugh added the Duplicate An existing issue was already created label Mar 10, 2017
@microsoft microsoft locked and limited conversation to collaborators Jun 19, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Duplicate An existing issue was already created
Projects
None yet
Development

No branches or pull requests

2 participants