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

Wrong syntax highlighting for Groovy GStrings when interpolating values #7103

Closed
FranzMartyn opened this issue Aug 27, 2024 · 2 comments
Closed

Comments

@FranzMartyn
Copy link

I am coming from this codewars issue , which uses codemirror 5 for it's editor.

Sometimes, codewars' editor gets the syntax highlighting for GStrings wrong when they contain interpolated values.

Codewars' editor does this:

image

instead of this (example from Intellij Idea):

image

But the syntax highlighting on codewars' editor works when adding curly braces:

image

@FranzMartyn
Copy link
Author

It seems to display how it should when a character, that is neither a letter, nor a digit, nor whitespace, comes after the interpolated value

image

@marijnh
Copy link
Member

marijnh commented Aug 28, 2024

Attached patch should help.

marijnh added a commit to codemirror/legacy-modes that referenced this issue Aug 28, 2024
FIX: Fix an issue in the Groovy mode where himBHsinterpolated variable style would
continue after whitespace.

Issue codemirror/codemirror5#7103
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

No branches or pull requests

2 participants