Skip to content

fix(language-support): support generic records - #4412

Merged
datho7561 merged 3 commits into
redhat-developer:mainfrom
its-miroma:fix-generic-records
Sep 1, 2026
Merged

fix(language-support): support generic records#4412
datho7561 merged 3 commits into
redhat-developer:mainfrom
its-miroma:fix-generic-records

Conversation

@its-miroma

Copy link
Copy Markdown
Contributor

Notice line 14:

Before After
image image

Signed-off-by: Miroma <its.miroma@proton.me>
@its-miroma
its-miroma force-pushed the fix-generic-records branch from f6f159f to 50b1937 Compare May 11, 2026 09:23
Signed-off-by: Miroma <its.miroma@proton.me>
Signed-off-by: Miroma <its.miroma@proton.me>
@wenytang-ms

Copy link
Copy Markdown
Contributor

LGTM, better to add a unit test case

@its-miroma

Copy link
Copy Markdown
Contributor Author

Hello @wenytang-ms, I just got back to this!

I don't see any tests for the tmLanguage in the repo yet, do you know where I can find them?

@datho7561 datho7561 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks good; improves the syntax highlighting for this case before the semantic tokens kick in. There's no need for unit tests; I don't think there's a good way to do that and we haven't been from what I understand.

Thanks, Miroma!

@datho7561
datho7561 merged commit 28e5962 into redhat-developer:main Sep 1, 2026
@datho7561 datho7561 added this to the End of July 2026 milestone Sep 1, 2026
@datho7561 datho7561 added the bug label Sep 1, 2026
@its-miroma

Copy link
Copy Markdown
Contributor Author

Thank you for merging!

I don't think there's a good way to do that

There are definitely ways to add tests for a tmLanguage, which might be interesting to explore:
https://github.com/PanAeon/vscode-tmgrammar-test

For example, by using the vscode-tmgrammar-snap command, one can create snapshots of the grammar scopes for certain snippets of Java source code, and track them in the repo.

@its-miroma
its-miroma deleted the fix-generic-records branch September 1, 2026 20:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants