Skip to content

Syntax highlighting broken with generics? #2114

Answered by suzmue
xlucas asked this question in Help
Discussion options

You must be logged in to vote

Hi @xlucas!

It appears that the TextMate based syntax highlighting does not appropriately highlight generic code. If you use the semantic tokens provided by gopls instead, it does support generics!

Add the following to your settings:

    "gopls": {
        "ui.semanticTokens": true
    }

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@hyangah
Comment options

@xlucas
Comment options

Answer selected by hyangah
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
None yet
3 participants