Skip to content

Refactor SemanticTokenTypes, SemanticTokenModifiers #1012

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

Merged
merged 3 commits into from
Jan 9, 2024
Merged

Refactor SemanticTokenTypes, SemanticTokenModifiers #1012

merged 3 commits into from
Jan 9, 2024

Conversation

krzyzanowskim
Copy link
Contributor

Refactor SyntaxHighlightingToken.Kind and SyntaxHighlightingToken.Modifiers into SemanticTokenTypes and SemanticTokenModifiers. This change moves types from SourceKitLSP to LanguageServerProtocol where it belongs.

SemanticTokenTypes is extended with additional types in SyntaxHighlightingToken.swift that is then used by the server.

Resolves #1010

@krzyzanowskim
Copy link
Contributor Author

I appreciate review/comment on that

Copy link
Member

@ahoppen ahoppen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you. Looks good to me

Comment on lines 50 to 51
public typealias Kind = SemanticTokenTypes
public typealias Modifiers = SemanticTokenModifiers
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need these typealias declarations or can we just use SemanticTokenTypes and SemanticTokenModifiers?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no. changed.

@krzyzanowskim krzyzanowskim requested a review from ahoppen January 8, 2024 22:51
@ahoppen ahoppen enabled auto-merge January 8, 2024 22:52
@ahoppen
Copy link
Member

ahoppen commented Jan 8, 2024

@swift-ci Please test

@ahoppen
Copy link
Member

ahoppen commented Jan 8, 2024

@swift-ci Please test Windows

@ahoppen ahoppen merged commit e0fe9d6 into swiftlang:main Jan 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

SyntaxHighlightingToken raw value differ from specification values
2 participants