Bend icon indicating copy to clipboard operation
Bend copied to clipboard

Report range on diagnostics

Open edusporto opened this issue 1 year ago • 0 comments

Currently, the diagnostic struct is defined as such:

pub struct Diagnostic {
  message: String,
  severity: Severity,
}

Some diagnostics can be related to code on a specific range of a file, like parsing errors for example. Currently, the location and file in which such errors occur is encoded within the message string, but that makes it difficult to get the source location of these diagnostics after they've been created.

This is especially useful to the language server for Bend we are currently developing.

edusporto avatar Jul 30 '24 18:07 edusporto