fn stub_functions<F>(context: &Context, module: &Module, functions: &[&str], mk_stub: F)
where
    F: Fn(&Builder),
{
    let builder = context.create_builder();
    for function in functions {
        for fv in get_function_by_unmangled_name(&module, function) {
            info!("Stubbing out function function {}", function);
            delete_body(&fv);
            let basic_block = context.append_basic_block(fv, "entry");
            builder.position_at_end(basic_block);
            mk_stub(&builder)
        }
    }
}
/// Stub out a list of functions by deleting the existing
/// body of each function and using mk_stub to construct a new body.
///
/// Functions are identified specified by names like "foo::bar"
/// and exclude the uniquifying hash code at the end.
Stub out a list of functions by deleting the existing
body of each function and using mk_stub to construct a new body.

Functions are identified specified by names like "foo::bar"
and exclude the uniquifying hash code at the end.
Stub out a list of functions by deleting the existing body of each function and using mk_stub to construct a new body . Functions are identified specified by names like " foo :: bar " and exclude the uniquifying hash code at the end .
fn stub_functions<F>(context: &Context, module: &Module, functions: &[&str], mk_stub: F)
where
    F: Fn(&Builder),
{
    let builder = context.create_builder();
    for function in functions {
        for fv in get_function_by_unmangled_name(&module, function) {
            info!("Stubbing out function function {}", function);
            delete_body(&fv);
            let basic_block = context.append_basic_block(fv, "entry");
            builder.position_at_end(basic_block);
            mk_stub(&builder)
        }
    }
}
fn stub_functions < F > ( context : & Context , module : & Module , functions : & [ & str ] , mk_stub : F ) where F : Fn ( & Builder ) , { let builder = context . create_builder ( ) ; for function in functions { for fv in get_function_by_unmangled_name ( & module , function ) { info ! ( " " function ) ; delete_body ( & fv ) ; let basic_block = context . append_basic_block ( fv , " " ) ; builder . position_at_end ( basic_block ) ; mk_stub ( & builder ) } } }
Stub out a list of functions by deleting the existing
body of each function and using mk_stub to construct a new body.
Stub out a list of functions by deleting the existing body of each function and using mk_stub to construct a new body .
context
&Context
module
&Module
functions
&[&str]
mk_stub
F
context
&Context
module
&Module
functions
&[&str]
mk_stub
F