Skip to content

Diagnostic formatter should highlight trivia in between consecutive highlight nodes #2208

Open
@ahoppen

Description

@ahoppen

Currently, if a diagnostic has two nodes to highlight, it will highlight them individually, leaving the trivia in between them non-highlighted. The easiest way to see this is by running

swift-parser-cli print-diags -s 'for x = 1; x < 10; x++ {}'
Screenshot 2023-09-16 at 09 14 02

Note that the space between x and = should also be highlighted.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions