pub trait LintLevelsProvider {
type LintExpectationId: Copy + Debug + Into<LintExpectationId>;
// Required methods
fn current_specs(
&self,
) -> &FxIndexMap<LintId, LevelSpec<Self::LintExpectationId>>;
fn insert(
&mut self,
id: LintId,
level_spec: LevelSpec<Self::LintExpectationId>,
);
fn get_lint_level_spec(
&self,
lint: &'static Lint,
sess: &Session,
) -> LevelSpec<Self::LintExpectationId>;
fn push_expectation(
&mut self,
id: Self::LintExpectationId,
expectation: LintExpectation,
);
fn mk_lint_expectation_id(
&self,
attr_id: AttrId,
attr_index: usize,
lint_index: u16,
) -> Self::LintExpectationId;
}Required Associated Types§
type LintExpectationId: Copy + Debug + Into<LintExpectationId>
Required Methods§
fn current_specs( &self, ) -> &FxIndexMap<LintId, LevelSpec<Self::LintExpectationId>>
fn insert(&mut self, id: LintId, level_spec: LevelSpec<Self::LintExpectationId>)
fn get_lint_level_spec( &self, lint: &'static Lint, sess: &Session, ) -> LevelSpec<Self::LintExpectationId>
fn push_expectation( &mut self, id: Self::LintExpectationId, expectation: LintExpectation, )
fn mk_lint_expectation_id( &self, attr_id: AttrId, attr_index: usize, lint_index: u16, ) -> Self::LintExpectationId
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".