pub struct Linter {
pub rules: FxHashSet<Rule>,
pub settings: LinterSettings,
/* private fields */
}Fields§
§rules: FxHashSet<Rule>§settings: LinterSettingsImplementations§
Source§impl Linter
impl Linter
pub fn lint(&mut self, file: &Parse<SourceFile>, text: &str) -> Vec<Violation>
pub fn with_default_rules() -> Self
pub fn with_rules(include: &[Rule], exclude: &[Rule]) -> Self
pub fn from(rules: impl IntoIterator<Item = Rule>) -> Self
Auto Trait Implementations§
impl Freeze for Linter
impl RefUnwindSafe for Linter
impl Send for Linter
impl Sync for Linter
impl Unpin for Linter
impl UnsafeUnpin for Linter
impl UnwindSafe for Linter
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more