Skip to content

Object field name highlighting breaks when field value contains colon characters #33

@risset

Description

@risset

For example, in

{
  a: 'b:c'
}

a will not be highlighted.

Adding a space after the colon in the following pattern in jsonnet-font-lock-keywords-1 seems to fix this, but not 100% sure if this would break anything else.

- '("[[:space:]].+:" . font-lock-keyword-face)
+ '("[[:space:]].+: " . font-lock-keyword-face)

Edit: actually since { a:'b:c' } is valid jsonnet, adding a space after the colon in the pattern wouldn't be a great solution :(

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions