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

Function parameter hints get offset if a string argument has a comma in it. #66

Closed
BscotchSeth opened this issue May 4, 2023 · 2 comments
Assignees
Labels
🔥 bug Something isn't working ⌨️ vscode The Stitch extension for VSCode

Comments

@BscotchSeth
Copy link
Member

The parameter hint helper seems to be using all commas in your function arguments, including commas in strings. This causes the hint helper to get offset. Example:

function do_stuff(a, b, c) {}

do_stuff("What, me?", "No!", 2);

If you click into the second argument slot, it will show that you're in the third (because there is a comma in the first argument).

@BscotchSeth BscotchSeth added the 🔥 bug Something isn't working label May 4, 2023
@adam-coster adam-coster added the ⌨️ vscode The Stitch extension for VSCode label May 4, 2023
@adam-coster adam-coster self-assigned this May 4, 2023
@adam-coster adam-coster added this to the GML Parser Upgrade milestone May 4, 2023
@adam-coster
Copy link
Member

This is caused by the super-simple logic currently in use to determine where you are in a function signature. Until I've replaced the parser we're just kinda stuck with this, but I've added this issue to the Parser Upgrade milestone!

@adam-coster
Copy link
Member

Resolved in the upcoming release!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🔥 bug Something isn't working ⌨️ vscode The Stitch extension for VSCode
Projects
None yet
Development

No branches or pull requests

2 participants