aboutsummaryrefslogtreecommitdiff
path: root/helix-core/src/diagnostic.rs
blob: 0ab7b6458150695d9a548935e0f786c118d4d923 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#[cfg_attr(feature = "debug", derive(Debug))]
#[derive(Eq, PartialEq)]
pub enum Severity {
    Error,
    Warning,
    Info,
    Hint,
}

#[cfg_attr(feature = "debug", derive(Debug))]
pub struct Range {
    pub start: usize,
    pub end: usize,
}

#[cfg_attr(feature = "debug", derive(Debug))]
pub struct Diagnostic {
    pub range: Range,
    pub line: usize,
    pub message: String,
    pub severity: Option<Severity>,
}