Skip to content

Don't include this function types in completeFunctionCalls#104479

Merged
mjbvz merged 1 commit intomicrosoft:masterfrom
xuanduc987:skip-this-parameters
Aug 18, 2020
Merged

Don't include this function types in completeFunctionCalls#104479
mjbvz merged 1 commit intomicrosoft:masterfrom
xuanduc987:skip-this-parameters

Conversation

@xuanduc987
Copy link
Contributor

@xuanduc987 xuanduc987 commented Aug 12, 2020

This PR fixes #104877

@mjbvz
Copy link
Collaborator

mjbvz commented Aug 12, 2020

What issue does this fix?

@mjbvz mjbvz self-assigned this Aug 12, 2020
@xuanduc987
Copy link
Contributor Author

Typescript allow annotating this parameter https://www.typescriptlang.org/docs/handbook/functions.html#this-parameters

function f(this: void) {
  // make sure `this` is unusable in this standalone function
}

Because this parameters are fake parameters, I think we should skip these.

@mjbvz
Copy link
Collaborator

mjbvz commented Aug 18, 2020

Thanks. Can you also create a normal issue to track this problem. This helps us track issues and verify this PR fixed it

@mjbvz mjbvz added this to the August 2020 milestone Aug 18, 2020
@xuanduc987
Copy link
Contributor Author

I had created #104877 to track this issue. Thanks.

@mjbvz mjbvz merged commit 63c711d into microsoft:master Aug 18, 2020
@mjbvz
Copy link
Collaborator

mjbvz commented Aug 18, 2020

Thanks! This will be in the next VS Code insiders build and is scheduled to ship with VS Code 1.49

@github-actions github-actions bot locked and limited conversation to collaborators Oct 2, 2020
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.

completeFunctionCalls should not add this parameters

2 participants