Enum cl_typeck::node::NodeSource
source · pub enum NodeSource<'a> {
}
Variants§
Root
Module(&'a Module)
Alias(&'a Alias)
Enum(&'a Enum)
Variant(&'a Variant)
Struct(&'a Struct)
Const(&'a Const)
Static(&'a Static)
Function(&'a Function)
Local(&'a Let)
Impl(&'a Impl)
Use(&'a Use)
Ty(&'a TyKind)
Implementations§
source§impl<'a> NodeSource<'a>
impl<'a> NodeSource<'a>
pub fn name(&self) -> Option<Sym>
sourcepub fn is_named_value(&self) -> bool
pub fn is_named_value(&self) -> bool
Returns true
if this NodeSource defines a named value
sourcepub fn is_named_type(&self) -> bool
pub fn is_named_type(&self) -> bool
Returns true
if this NodeSource defines a named type
sourcepub fn is_anon_type(&self) -> bool
pub fn is_anon_type(&self) -> bool
Returns true
if this NodeSource refers to a Ty with no name
sourcepub fn is_impl(&self) -> bool
pub fn is_impl(&self) -> bool
Returns true
if this NodeSource refers to an Impl block
sourcepub fn is_use_import(&self) -> bool
pub fn is_use_import(&self) -> bool
Returns true
if this NodeSource refers to a Use import
Trait Implementations§
source§impl<'a> Clone for NodeSource<'a>
impl<'a> Clone for NodeSource<'a>
source§fn clone(&self) -> NodeSource<'a>
fn clone(&self) -> NodeSource<'a>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl<'a> Debug for NodeSource<'a>
impl<'a> Debug for NodeSource<'a>
source§impl Display for NodeSource<'_>
impl Display for NodeSource<'_>
source§impl<'a> Hash for NodeSource<'a>
impl<'a> Hash for NodeSource<'a>
source§impl<'a> PartialEq for NodeSource<'a>
impl<'a> PartialEq for NodeSource<'a>
source§fn eq(&self, other: &NodeSource<'a>) -> bool
fn eq(&self, other: &NodeSource<'a>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl<'a> TypeResolvable<'a> for NodeSource<'a>
impl<'a> TypeResolvable<'a> for NodeSource<'a>
impl<'a> Copy for NodeSource<'a>
impl<'a> Eq for NodeSource<'a>
impl<'a> StructuralPartialEq for NodeSource<'a>
Auto Trait Implementations§
impl<'a> Freeze for NodeSource<'a>
impl<'a> RefUnwindSafe for NodeSource<'a>
impl<'a> Send for NodeSource<'a>
impl<'a> Sync for NodeSource<'a>
impl<'a> Unpin for NodeSource<'a>
impl<'a> UnwindSafe for NodeSource<'a>
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