Skip to main content

diag_lint_level

Function diag_lint_level 

Source
pub fn diag_lint_level<'a, D: Diagnostic<'a, ()> + 'a>(
    sess: &'a Session,
    lint: &'static Lint,
    level: LevelAndSource,
    span: Option<MultiSpan>,
    decorate: D,
)
Expand description

The innermost function for emitting lints implementing the Diagnostic trait.

If you are looking to implement a lint, look for higher level functions, for example:

This function will replace lint_level once all its callers have been replaced with diag_lint_level.