pub struct ImportPathHop {
pub from: String,
pub to: String,
pub type_only: bool,
pub dynamic: bool,
pub import_line: Option<u32>,
}Expand description
One import edge on an ImportPathTrace.
Fields§
§from: StringThe importing module, root-relative.
to: StringThe imported module, root-relative.
type_only: boolWhether every symbol on this edge is type-only, so the hop is erased at
build time. Type-only hops are reported, never skipped: an import type
chain is a real compile-time coupling.
dynamic: boolWhether the edge carries a runtime value but no static one: the target
loads only on demand (import(), a lazy glob or template pattern) or
on another thread (a worker URL, child_process.fork). False for a
static hop and for a type-only hop.
import_line: Option<u32>1-based line in from of the imported binding that creates this edge:
the first value-carrying symbol on the import, or the first symbol when
every symbol is type-only. On a multi-line import that is the binding’s
own line, not the import keyword’s. Absent when the edge carries no
span or the source could not be read.
Trait Implementations§
Source§impl Debug for ImportPathHop
impl Debug for ImportPathHop
impl Eq for ImportPathHop
Source§impl PartialEq for ImportPathHop
impl PartialEq for ImportPathHop
Source§impl Serialize for ImportPathHop
impl Serialize for ImportPathHop
impl StructuralPartialEq for ImportPathHop
Auto Trait Implementations§
impl Freeze for ImportPathHop
impl RefUnwindSafe for ImportPathHop
impl Send for ImportPathHop
impl Sync for ImportPathHop
impl Unpin for ImportPathHop
impl UnsafeUnpin for ImportPathHop
impl UnwindSafe for ImportPathHop
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
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.