pub trait LintEmitter: Copy {
type Id: Copy;
// Required method
fn emit_node_span_lint(
self,
lint: &'static Lint,
hir_id: Self::Id,
span: impl Into<MultiSpan>,
decorator: impl for<'a> LintDiagnostic<'a, ()> + DynSend + 'static,
);
}
Expand description
Used to avoid depending on rustc_middle
in rustc_attr_parsing
.
Always the TyCtxt
.
Required Associated Types§
Required Methods§
fn emit_node_span_lint( self, lint: &'static Lint, hir_id: Self::Id, span: impl Into<MultiSpan>, decorator: impl for<'a> LintDiagnostic<'a, ()> + DynSend + 'static, )
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.