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

Fix highlighting for computed map keys #953

Closed
wants to merge 2 commits into from
Closed

Conversation

dbanck
Copy link
Member

@dbanck dbanck commented Mar 1, 2022

This PR adds the missing : operator for computed map keys. Until now the end regex wasn't able to match anything and claimed the rest of the file as meta.mapping.key.

Before

CleanShot 2022-03-02 at 17 35 07@2x

After

CleanShot 2022-03-02 at 17 35 23@2x

Closes #809

dbanck added 2 commits March 1, 2022 11:25
The regex only matched for a `=` and was never able to find
a matching end, though matching everything until the end of
the file. Adding a `:` fixes this.
@dbanck dbanck self-assigned this Mar 1, 2022
@dbanck dbanck added bug Something isn't working syntax labels Mar 1, 2022
@dbanck
Copy link
Member Author

dbanck commented Mar 4, 2022

Moved

@dbanck dbanck closed this Mar 4, 2022
@radeksimko radeksimko deleted the b-map-key-syntax branch March 4, 2022 17:03
@github-actions
Copy link

github-actions bot commented Apr 4, 2022

I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 4, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working syntax
Projects
None yet
Development

Successfully merging this pull request may close these issues.

non-literal string expression as map key breaks syntax highlighting
1 participant