pub struct UnusedImport {
pub file: String,
pub domain: String,
pub alias: Option<String>,
pub line: u32,
}Expand description
An advisory record: a file IMPORTs a domain it never references. Such an
import is inert — no domain.atom in that file mentions it, so removing it
would not change the result. It is almost always a leftover or a forgotten
domain. prefix. Purely informational — it never changes the verdict.
Fields§
§file: StringThe source that declared the unused IMPORT.
domain: StringThe imported domain that is never referenced from file.
alias: Option<String>The local alias, if the import used AS <alias>.
line: u321-based line of the IMPORT statement in file.
Trait Implementations§
Source§impl Clone for UnusedImport
impl Clone for UnusedImport
Source§fn clone(&self) -> UnusedImport
fn clone(&self) -> UnusedImport
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for UnusedImport
impl Debug for UnusedImport
impl Eq for UnusedImport
Source§impl Ord for UnusedImport
impl Ord for UnusedImport
Source§fn cmp(&self, other: &UnusedImport) -> Ordering
fn cmp(&self, other: &UnusedImport) -> Ordering
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for UnusedImport
impl PartialEq for UnusedImport
Source§fn eq(&self, other: &UnusedImport) -> bool
fn eq(&self, other: &UnusedImport) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl PartialOrd for UnusedImport
impl PartialOrd for UnusedImport
impl StructuralPartialEq for UnusedImport
Auto Trait Implementations§
impl Freeze for UnusedImport
impl RefUnwindSafe for UnusedImport
impl Send for UnusedImport
impl Sync for UnusedImport
impl Unpin for UnusedImport
impl UnsafeUnpin for UnusedImport
impl UnwindSafe for UnusedImport
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