pub struct LintConfig {
pub disabled_rules: HashSet<String>,
pub severity_overrides: HashMap<String, Severity>,
pub exclude_patterns: Vec<String>,
pub tag_namespaces: Vec<String>,
pub ads: Option<AdsConfig>,
}Expand description
Configuration for lint rule suppression and severity overrides.
Fields§
§disabled_rules: HashSet<String>§severity_overrides: HashMap<String, Severity>§exclude_patterns: Vec<String>§tag_namespaces: Vec<String>Extra tag namespaces recognised in addition to the built-in set.
ads: Option<AdsConfig>ADS enforcement configuration. None (the default) leaves the ADS
presence checks off; an ads: block in the config enables them.
Implementations§
Source§impl LintConfig
impl LintConfig
pub fn load(path: &Path) -> Result<Self>
pub fn find_in_ancestors(start_path: &Path) -> Option<PathBuf>
pub fn merge(&mut self, other: &LintConfig)
pub fn is_disabled(&self, rule: &LintRule) -> bool
pub fn build_exclude_set(&self) -> Option<GlobSet>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for LintConfig
impl RefUnwindSafe for LintConfig
impl Send for LintConfig
impl Sync for LintConfig
impl Unpin for LintConfig
impl UnsafeUnpin for LintConfig
impl UnwindSafe for LintConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more