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

The unrecognized directive error for an unrecognized directive without values reports strings from the next line #3389

Open
vasilmkd opened this issue Dec 20, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@vasilmkd
Copy link

Version(s)
1.5.4

To Reproduce

//> using optionsdeprecation

//> using options -deprecation

By debugging the received BSP diagnostic message, these is the line and column information it contains:
Start line: 0
Start column: 28
End line: 0
End column: 40

Notice that there are no 40 characters in the first line. In fact, (0, 28) is just past the "optionsdeprecation" string.

Expected behaviour
Possibly a new error message, just "Unrecognized directive: optionsdeprecation" without the "with values" part and it highlights the unrecognized directive "optionsdeprecation".

The reported diagnostic message as it is today, looks weird in IDEA.
https://youtrack.jetbrains.com/issue/SCL-23343/Scala-CLI-next-code-line-is-highlighted-if-using-directive-is-incorrect

@vasilmkd vasilmkd added the bug Something isn't working label Dec 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant