Migrate PanicNonStr, RawPtrComparison, RawPtrToInt diagnostics
This commit is contained in:
parent
c48f482813
commit
584e5d4c4f
3 changed files with 41 additions and 23 deletions
|
@ -39,3 +39,27 @@ pub(crate) struct StaticAccessErr {
|
|||
#[help(const_eval::teach_help)]
|
||||
pub teach: Option<()>,
|
||||
}
|
||||
|
||||
#[derive(SessionDiagnostic)]
|
||||
#[error(const_eval::raw_ptr_to_int)]
|
||||
#[note]
|
||||
#[note(const_eval::note2)]
|
||||
pub(crate) struct RawPtrToIntErr {
|
||||
#[primary_span]
|
||||
pub span: Span,
|
||||
}
|
||||
|
||||
#[derive(SessionDiagnostic)]
|
||||
#[error(const_eval::raw_ptr_comparison)]
|
||||
#[note]
|
||||
pub(crate) struct RawPtrComparisonErr {
|
||||
#[primary_span]
|
||||
pub span: Span,
|
||||
}
|
||||
|
||||
#[derive(SessionDiagnostic)]
|
||||
#[error(const_eval::panic_non_str)]
|
||||
pub(crate) struct PanicNonStrErr {
|
||||
#[primary_span]
|
||||
pub span: Span,
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue