pub trait Issue:
Send
+ Sync
+ NonLocalValue
+ ValueDebug {
// Required methods
fn file_path<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<FileSystemPath>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn stage(&self) -> IssueStage;
fn title<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<StyledString>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
// Provided methods
fn severity(&self) -> IssueSeverity { ... }
fn description<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Option<StyledString>>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn detail<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Option<StyledString>>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn documentation_link(&self) -> RcStr { ... }
fn source(&self) -> Option<IssueSource> { ... }
fn additional_sources<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<AdditionalIssueSource>>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
}Required Methods§
Sourcefn file_path<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<FileSystemPath>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn file_path<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<FileSystemPath>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
The file path that generated the issue, displayed to the user as message header.
Sourcefn stage(&self) -> IssueStage
fn stage(&self) -> IssueStage
The stage of the compilation process at which the issue occurred. This is used to sort issues.
Sourcefn title<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<StyledString>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn title<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<StyledString>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
The issue title should be descriptive of the issue, but should be a single line. This is displayed to the user directly under the issue header.
Provided Methods§
Sourcefn severity(&self) -> IssueSeverity
fn severity(&self) -> IssueSeverity
Severity allows the user to filter out unimportant issues, with Bug being the highest priority and Info being the lowest.
Sourcefn description<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Option<StyledString>>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn description<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Option<StyledString>>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
A more verbose message of the issue, appropriate for providing multiline information of the issue.
Sourcefn detail<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Option<StyledString>>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn detail<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Option<StyledString>>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Full details of the issue, appropriate for providing debug level information. Only displayed if the user explicitly asks for detailed messages (not to be confused with severity).
Sourcefn documentation_link(&self) -> RcStr
fn documentation_link(&self) -> RcStr
A link to relevant documentation of the issue. Only displayed in console if the user explicitly asks for detailed messages.
Sourcefn source(&self) -> Option<IssueSource>
fn source(&self) -> Option<IssueSource>
The source location that caused the issue. Eg, for a parsing error it should point at the offending character. Displayed to the user alongside the title/description.
Sourcefn additional_sources<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<AdditionalIssueSource>>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn additional_sources<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<AdditionalIssueSource>>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Additional source locations related to this issue (e.g., generated code from a loader). Each source includes a description and location. These are displayed alongside the primary source to give users full context about the error.