Skip to main content

DeadCodeFilters

Struct DeadCodeFilters 

Source
pub struct DeadCodeFilters {
Show 31 fields pub unused_files: bool, pub unused_exports: bool, pub unused_deps: bool, pub unused_types: bool, pub private_type_leaks: bool, pub deprecated_exports_in_use: bool, pub unused_enum_members: bool, pub unused_class_members: bool, pub unused_store_members: bool, pub unprovided_injects: bool, pub unrendered_components: bool, pub unused_component_props: bool, pub unused_component_emits: bool, pub unused_component_inputs: bool, pub unused_component_outputs: bool, pub unused_svelte_events: bool, pub unused_server_actions: bool, pub unused_load_data_keys: bool, pub unresolved_imports: bool, pub unlisted_deps: bool, pub duplicate_exports: bool, pub circular_deps: bool, pub re_export_cycles: bool, pub boundary_violations: bool, pub policy_violations: bool, pub stale_suppressions: bool, pub unused_catalog_entries: bool, pub empty_catalog_groups: bool, pub unresolved_catalog_references: bool, pub unused_dependency_overrides: bool, pub misconfigured_dependency_overrides: bool,
}
Expand description

Issue-type filters for the dead-code analysis.

Each flag opts one issue type into the report. When no flag is enabled the analysis reports every issue type.

Fields§

§unused_files: bool

Files never reached from any entry point.

§unused_exports: bool

Exported symbols never imported elsewhere.

§unused_deps: bool

Declared dependencies never imported.

§unused_types: bool

Exported types never referenced.

§private_type_leaks: bool

Exported APIs that expose non-exported types.

§deprecated_exports_in_use: bool

Exports marked @deprecated that are still in use.

§unused_enum_members: bool

Enum members never read.

§unused_class_members: bool

Class members never used outside their declaration.

§unused_store_members: bool

Store members (for example Pinia) never used outside the store.

§unprovided_injects: bool

inject calls with no matching provide.

§unrendered_components: bool

Components never rendered by any template or JSX.

§unused_component_props: bool

Declared component props never used.

§unused_component_emits: bool

Declared component emits never used.

§unused_component_inputs: bool

Declared component inputs never bound.

§unused_component_outputs: bool

Declared component outputs never listened to.

§unused_svelte_events: bool

Svelte component events never listened to.

§unused_server_actions: bool

Server actions never invoked.

§unused_load_data_keys: bool

load data keys never read by the consuming page.

§unresolved_imports: bool

Imports that do not resolve to a file or package.

§unlisted_deps: bool

Imported packages missing from the dependency manifest.

§duplicate_exports: bool

The same symbol exported more than once.

§circular_deps: bool

Circular import chains.

§re_export_cycles: bool

Cycles formed through re-export chains.

§boundary_violations: bool

Imports that cross configured architecture boundaries.

§policy_violations: bool

Violations of configured dependency policy rules.

§stale_suppressions: bool

Suppression comments that no longer match a finding.

§unused_catalog_entries: bool

Catalog entries never referenced by a workspace package.

§empty_catalog_groups: bool

Catalog groups that contain no entries.

§unresolved_catalog_references: bool

catalog: references without a matching catalog entry.

§unused_dependency_overrides: bool

Dependency overrides that never affect a resolved package.

§misconfigured_dependency_overrides: bool

Dependency overrides that cannot apply as written.

Implementations§

Source§

impl DeadCodeFilters

Source

pub fn enable_registry_selector(&mut self, selector: &str) -> bool

Enable the issue filter addressed by a shared registry selector.

Returns false when the selector is not registered for dead-code filtering. Callers that expose user input should surface their own validation error with the accepted registry values.

Trait Implementations§

Source§

impl Clone for DeadCodeFilters

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for DeadCodeFilters

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for DeadCodeFilters

Source§

fn default() -> Self

Returns the “default value” for a type. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> DynClone for T
where T: Clone,

Source§

fn __clone_box(&self, _: Private) -> *mut ()

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<'a, T> FromIn<'a, T> for T

Source§

fn from_in(t: T, _: &'a Allocator) -> T

Converts to this type from the input type within the given allocator.
Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self> ⓘ

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self> ⓘ

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
where F: FnOnce(&Self) -> bool,

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
Source§

impl<'a, T, U> IntoIn<'a, U> for T
where U: FromIn<'a, T>,

Source§

fn into_in(self, allocator: &'a Allocator) -> U

Converts this type into the (usually inferred) input type within the given allocator.
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘ
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more