Skip to content

Pico VS Code extension #14

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 8 commits into from
Sep 2, 2024
Merged

Pico VS Code extension #14

merged 8 commits into from
Sep 2, 2024

Conversation

sungshik
Copy link
Collaborator

This PR extends the syntax-highlighting-only VS Code extension (with generated TextMate grammars) with support for Pico (in addition to Rascal). To this end, this PR:

  • Makes a few changes to the configuration of the VS Code extension
  • Reorganizes the code to generate grammars for use in the VS Code extension

Note: None of the actual conversion code is affected.

Copy link
Collaborator Author

@sungshik sungshik left a comment

Choose a reason for hiding this comment

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

A few review comments

the special VS Code extension
}

module VSCodeRascal
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

This is essentially a rename of the old VSCode module:

  • Function main was a bit streamlined
  • Function getRscGrammar is identical to before

@@ -42,10 +42,22 @@ syntax Expression
| min: Expression lhs "-" Expression rhs)
;

lexical Id = [a-z][a-z0-9]* !>> [a-z0-9];
lexical Id = ([a-z][a-z0-9]*) !>> [a-z0-9] \ Keyword;
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Added this condition (diverging slightly from lang::pico::\syntax::Main) to make the highlighting a bit nicer)

@sungshik sungshik marked this pull request as ready for review August 23, 2024 11:16
@sungshik sungshik marked this pull request as draft August 23, 2024 11:17
@sungshik sungshik marked this pull request as ready for review August 23, 2024 11:17
Copy link
Member

@DavyLandman DavyLandman left a comment

Choose a reason for hiding this comment

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

LGTM 👍🏼

@sungshik sungshik merged commit c7ed45e into main Sep 2, 2024
2 checks passed
@sungshik sungshik deleted the pico-vscode-extension branch September 2, 2024 07:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants