pub fn ret_val(mut self, value: Value, location: Option<Location>) -> Value {
        self.make_value(Instruction::ReturnValue(
            value.get_type(self.context),
            value,
            location,
        ))
    }
/// Record a return from the function which closes the block.
///
/// # Examples
///
/// ```
/// # use yair::*;
/// # let mut context = Context::new();
/// # let module = context.create_module().build();
/// # let u32_ty = context.get_uint_type(32);
/// # let function = module.create_function(&mut context).with_name("func").with_return_type(u32_ty).with_arg("a", u32_ty).build();
/// # let block = function.create_block(&mut context).build();
/// # let return_value = function.get_arg(&context, 0);
/// # let mut instruction_builder = block.create_instructions(&mut context);
/// # let location = None;
/// instruction_builder.ret_val(return_value, location);
/// ```
Record a return from the function which closes the block.
Record a return from the function which closes the block .
pub fn ret_val(mut self, value: Value, location: Option<Location>) -> Value {
        self.make_value(Instruction::ReturnValue(
            value.get_type(self.context),
            value,
            location,
        ))
    }
pub fn ret_val ( mut self , value : Value , location : Option < Location > ) -> Value { self . make_value ( Instruction :: ReturnValue ( value . get_type ( self . context ) , value , location , ) ) }
Record a return from the function which closes the block.
Record a return from the function which closes the block .
mut self
value
Value
location
Option<Location>
mut self
value
Value
location
Option<Location>
examples
None
use yair::*;
None
let mut context = context::new();
None
let module = context.create_module().build();
None
let u32_ty = context.get_uint_type(32);
None
let function = module.create_function(&mut context).with_name("func").with_return_type(u32_ty).with_arg("a", u32_ty).build();
None
let block = function.create_block(&mut context).build();
None
let return_value = function.get_arg(&context, 0);
None
let mut instruction_builder = block.create_instructions(&mut context);
None
let location = none;
instruction_builder.ret_val(return_value, location);
```
instruction_builder . ret_val ( return_value location ) ; ` ` `