Struct ast_demangle::rust_v0::Symbol
source · [−]pub struct Symbol<'a> {
pub version: Option<u64>,
pub path: Rc<Path<'a>>,
pub instantiating_crate: Option<Rc<Path<'a>>>,
pub vendor_specific_suffix: Option<&'a str>,
}Fields
version: Option<u64>path: Rc<Path<'a>>instantiating_crate: Option<Rc<Path<'a>>>vendor_specific_suffix: Option<&'a str>Implementations
sourceimpl<'a> Symbol<'a>
impl<'a> Symbol<'a>
sourcepub fn display(&self, style: DisplayStyle) -> impl Display + '_
pub fn display(&self, style: DisplayStyle) -> impl Display + '_
Returns an object that implements Display for printing the symbol.
sourcepub fn parse_from_str(
input: &'a str
) -> Result<(Self, &'a str), ParseSymbolError>
pub fn parse_from_str(
input: &'a str
) -> Result<(Self, &'a str), ParseSymbolError>
Parses input with Rust
v0 syntax,
returns a tuple that contains a Symbol object and an &str object containing the suffix that is
not part of the the Rust v0 syntax.
Errors
Returns ParseSymbolError if input does not start with a valid prefix with Rust v0 syntax.
Trait Implementations
sourceimpl<'a> Ord for Symbol<'a>
impl<'a> Ord for Symbol<'a>
sourceimpl<'a> PartialOrd<Symbol<'a>> for Symbol<'a>
impl<'a> PartialOrd<Symbol<'a>> for Symbol<'a>
sourcefn partial_cmp(&self, other: &Symbol<'a>) -> Option<Ordering>
fn partial_cmp(&self, other: &Symbol<'a>) -> Option<Ordering>
This method returns an ordering between self and other values if one exists. Read more
1.0.0 · sourcefn lt(&self, other: &Rhs) -> bool
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self and other) and is used by the <=
operator. Read more
impl<'a> Eq for Symbol<'a>
impl<'a> StructuralEq for Symbol<'a>
impl<'a> StructuralPartialEq for Symbol<'a>
Auto Trait Implementations
impl<'a> RefUnwindSafe for Symbol<'a>
impl<'a> !Send for Symbol<'a>
impl<'a> !Sync for Symbol<'a>
impl<'a> Unpin for Symbol<'a>
impl<'a> UnwindSafe for Symbol<'a>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more