pub struct DagInit<'a> { /* private fields */ }Implementations§
Source§impl<'a> DagInit<'a>
impl<'a> DagInit<'a>
Sourcepub fn args(self) -> DagIter<'a> ⓘ
pub fn args(self) -> DagIter<'a> ⓘ
Returns an iterator over the arguments of the dag.
The iterator yields tuples (Option<&str>, TypedInit) where the first element is the
argument name, or None if the argument is unnamed (e.g. positional args like
(add r0, r1, r2)).
Use DagInit::num_args and DagInit::get for indexed access if you only need values.
Sourcepub fn name(self, index: usize) -> Option<&'a str>
pub fn name(self, index: usize) -> Option<&'a str>
Returns the name of the argument at the given index.
Trait Implementations§
Source§impl<'a> TryFrom<RecordValue<'a>> for DagInit<'a>
impl<'a> TryFrom<RecordValue<'a>> for DagInit<'a>
Source§type Error = SourceError<TableGenError>
type Error = SourceError<TableGenError>
The type returned in the event of a conversion error.
impl<'a> Copy for DagInit<'a>
impl<'a> Eq for DagInit<'a>
impl<'a> StructuralPartialEq for DagInit<'a>
Auto Trait Implementations§
impl<'a> Freeze for DagInit<'a>
impl<'a> RefUnwindSafe for DagInit<'a>
impl<'a> !Send for DagInit<'a>
impl<'a> !Sync for DagInit<'a>
impl<'a> Unpin for DagInit<'a>
impl<'a> UnwindSafe for DagInit<'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