Skip to content

Highlight type parameters consistently #2230

Closed
Closed
@RunDevelopment

Description

@RunDevelopment

Search Terms

generic type parameters, semantic highlighting

Problem

I expected type parameters to have the same highlighting everywhere, but their highlighting is inconsistent. Type parameters are currently highlighted where they are defined and nowhere else. (This is only the case on class and interface pages. Type parameters are not highlighted at all in other pages. This is likely related to #2227.)

image

Suggested Solution

I have two main thoughts on this:

  1. Highlighting type parameters everywhere would be useful, because they are very important.
  2. Currently, only linked identifiers are highlighted. So highlighting type parameters without linking them would be inconsistent.

So I would suggest to either remove highlighting for type parameters everywhere, or to highlight them everywhere and add links for them. If consistency is not as important (e.g. because more highlighting is planned in the future, idk), then I think that type parameters should be highlighted everywhere, even without them linking to anything. Depends on what is more important.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions