bevy_lint/lints/restriction/
mod.rs1use rustc_lint::{Level, Lint, LintStore};
10
11use crate::lint::LintGroup;
12
13pub mod missing_reflect;
14pub mod panicking_methods;
15
16pub(crate) struct Restriction;
17
18impl LintGroup for Restriction {
19 const NAME: &str = "bevy::restriction";
20 const LEVEL: Level = Level::Allow;
21 const LINTS: &[&Lint] = &[
22 missing_reflect::MISSING_REFLECT,
23 panicking_methods::PANICKING_METHODS,
24 ];
25
26 fn register_passes(store: &mut LintStore) {
27 store.register_late_pass(|_| Box::new(missing_reflect::MissingReflect::default()));
28 store.register_late_pass(|_| Box::new(panicking_methods::PanickingMethods::default()));
29 }
30}