Enum calyx_ir::StaticControl
source · pub enum StaticControl {
Repeat(StaticRepeat),
Enable(StaticEnable),
Par(StaticPar),
Seq(StaticSeq),
If(StaticIf),
Empty(Empty),
Invoke(StaticInvoke),
}
Expand description
Control AST nodes.
Variants§
Repeat(StaticRepeat)
Essentially a Static While Loop
Enable(StaticEnable)
Par(StaticPar)
Seq(StaticSeq)
If(StaticIf)
Empty(Empty)
Invoke(StaticInvoke)
Implementations§
source§impl StaticControl
impl StaticControl
sourcepub fn seq(stmts: Vec<StaticControl>, latency: u64) -> Self
pub fn seq(stmts: Vec<StaticControl>, latency: u64) -> Self
Convience constructor for static enable.
sourcepub fn par(stmts: Vec<StaticControl>, latency: u64) -> Self
pub fn par(stmts: Vec<StaticControl>, latency: u64) -> Self
Convience constructor for static enable.
sourcepub fn static_if(
port: RRC<Port>,
tbranch: Box<StaticControl>,
fbranch: Box<StaticControl>,
latency: u64
) -> Self
pub fn static_if( port: RRC<Port>, tbranch: Box<StaticControl>, fbranch: Box<StaticControl>, latency: u64 ) -> Self
Convience constructor for static if
sourcepub fn repeat(num_repeats: u64, latency: u64, body: Box<StaticControl>) -> Self
pub fn repeat(num_repeats: u64, latency: u64, body: Box<StaticControl>) -> Self
Convience constructor for static if
sourcepub fn get_attribute(&self, attr: Attribute) -> Option<u64>
pub fn get_attribute(&self, attr: Attribute) -> Option<u64>
Returns the value of an attribute if present
sourcepub fn get_latency(&self) -> u64
pub fn get_latency(&self) -> u64
Returns the value of an attribute if present
Trait Implementations§
source§impl Debug for StaticControl
impl Debug for StaticControl
source§impl<'a> From<&'a StaticControl> for GenericControl<'a>
impl<'a> From<&'a StaticControl> for GenericControl<'a>
source§fn from(sc: &'a StaticControl) -> Self
fn from(sc: &'a StaticControl) -> Self
Converts to this type from the input type.
source§impl From<Rc<RefCell<StaticGroup>>> for StaticControl
impl From<Rc<RefCell<StaticGroup>>> for StaticControl
source§fn from(sgroup: RRC<StaticGroup>) -> Self
fn from(sgroup: RRC<StaticGroup>) -> Self
Converts to this type from the input type.
source§impl From<StaticControl> for Control
impl From<StaticControl> for Control
source§fn from(sc: StaticControl) -> Self
fn from(sc: StaticControl) -> Self
Converts to this type from the input type.
source§impl From<StaticEnable> for StaticControl
impl From<StaticEnable> for StaticControl
source§fn from(se: StaticEnable) -> Self
fn from(se: StaticEnable) -> Self
Converts to this type from the input type.
source§impl GetAttributes for StaticControl
impl GetAttributes for StaticControl
source§fn get_mut_attributes(&mut self) -> &mut Attributes
fn get_mut_attributes(&mut self) -> &mut Attributes
Returns a mutable
Attributes
instancesource§fn get_attributes(&self) -> &Attributes
fn get_attributes(&self) -> &Attributes
Returns an
Attributes
instanceAuto Trait Implementations§
impl !RefUnwindSafe for StaticControl
impl !Send for StaticControl
impl !Sync for StaticControl
impl Unpin for StaticControl
impl !UnwindSafe for StaticControl
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