Skip to content

semantic highlighting: multi-line token? #982

Description

@Eskibear

It's about Text Block in Java, see https://openjdk.java.net/jeps/355

class Foo {
  private String bar = """
    hello
    world
  """;
}

Intuitively I think it should be a token of String kind, covering """\n hello\n world\n """ across lines. But according to current design, it seems not possilbe to define multi-line tokens. I tried in vscode but not working (AFAIK for the moment only vscode implements the feature). I don't know if it's a bug of vscode, or by design.

If it's by design, I have to seperate the text block by defining several tokens for each line. I just feel a little bit unnatural about it. Any clarification to help me understand more?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions