pub struct Function { /* private fields */ }Implementations§
Source§impl Function
impl Function
Sourcepub fn get_blocks(&self) -> Vec<Block>
pub fn get_blocks(&self) -> Vec<Block>
Returns all blocks in the function.
Sourcepub fn get_block(&self, block: &Block) -> Option<&BlockData>
pub fn get_block(&self, block: &Block) -> Option<&BlockData>
Returns a reference to the block data.
Sourcepub fn get_block_mut(&mut self, block: &Block) -> Option<&mut BlockData>
pub fn get_block_mut(&mut self, block: &Block) -> Option<&mut BlockData>
Returns a mutable reference to the block data.
Sourcepub fn entry_block(&self) -> Option<Block>
pub fn entry_block(&self) -> Option<Block>
Returns the entry block of the function.
Sourcepub fn get_val_type(&self, val: Value) -> IRType
pub fn get_val_type(&self, val: Value) -> IRType
Returns the type of the given value. The caller must call this method with the value generated by this builder.
Sourcepub fn get_var_types(&self) -> &HashMap<Variable, IRType>
pub fn get_var_types(&self) -> &HashMap<Variable, IRType>
Returns the map of the types of all variables in the function.
Sourcepub fn get_val_types(&self) -> &HashMap<Value, IRType>
pub fn get_val_types(&self) -> &HashMap<Value, IRType>
Returns the map of the types of all values in the function.
Sourcepub fn get_var_type(&self, var: Variable) -> IRType
pub fn get_var_type(&self, var: Variable) -> IRType
Returns the type of the given variable. The caller must call this method with the variable generated by this builder.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Function
impl RefUnwindSafe for Function
impl Send for Function
impl Sync for Function
impl Unpin for Function
impl UnsafeUnpin for Function
impl UnwindSafe for Function
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