-
Notifications
You must be signed in to change notification settings - Fork 33
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
PlusCal syntax highlighting breaks if --algorithm is not on line of open comment #104
Comments
You're right, in a couple of cases the extension doesn't capture boundaries of a PlusCal algorithm correctly. There's a quick fix for this particular issue, but unfortunately, it brings other highlighting problems. VS Code has some limitations on grammar parsing, especially when it comes to embedded languages (PlusCal inside TLA+). So, for the time being, I'll leave the highlighting rules as they are. But I'll add some kind of Caveats section to the Wiki. Thanks for the idea! |
Here it is: Caveats |
Thanks, that looks good to me. |
There's an attempt to improve VS Code highlighting capabilities: microsoft/vscode#77133. I hope the result will allow us to fix this issue. |
BTW, it's also better to keep the closing curly bracket on the last comment line:
The extension starting with version 1.2 handles it better. |
A similar problem if opening bracket of define is on the next line: define
{
...
} |
This is extremely minor, but maybe worth noting in a wiki page. PlusCal syntax highlighting won't work if the algorithm is written as:
However, it does work if the algorithm is written as:
The text was updated successfully, but these errors were encountered: