Skip to content

Remove assert in symbolToParameterDeclaration #24136

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

Merged
merged 2 commits into from
May 16, 2018
Merged

Conversation

mhegazy
Copy link
Contributor

@mhegazy mhegazy commented May 15, 2018

Also adds a test.

@mhegazy mhegazy requested a review from weswigham May 15, 2018 19:22
//// }


verify.rangeAfterCodeFix("props: { isLoading: any; update: (...arg0: any) => void; }",/*includeWhiteSpace*/ undefined, /*errorCode*/ undefined, 0);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Type is wrong. Should be ...arg0: any[] that little bit not being implemented is probably why it was asserted.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, was looking into this

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In maybeAddJsSyntheticRestParameter we just to a switch to create an array type when building the last type if it's a rest type, probably just need to do a similar thing in symbolToParameterDeclaration.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed.

@mhegazy mhegazy merged commit 21acf4f into master May 16, 2018
@mhegazy mhegazy deleted the inferFromUsageFixes branch May 16, 2018 21:15
@microsoft microsoft locked and limited conversation to collaborators Jul 31, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants