pub(crate) fn unhandled_intrinsic(
    control_flow_graph: &mut il::ControlFlowGraph,
    instruction: &capstone::Instr,
) -> Result<()> {
    let block_index = {
        let block = control_flow_graph.new_block()?;

        block.intrinsic(il::Intrinsic::new(
            instruction.mnemonic.clone(),
            format!("{} {}", instruction.mnemonic, instruction.op_str),
            Vec::new(),
            None,
            None,
            instruction.bytes.get(0..4).unwrap().to_vec(),
        ));

        block.index()
    };

    control_flow_graph.set_entry(block_index)?;
    control_flow_graph.set_exit(block_index)?;

    Ok(())
}
// A convenience function for turning unhandled instructions into intrinsics
A convenience function for turning unhandled instructions into intrinsics
A convenience function for turning unhandled instructions into intrinsics
pub(crate) fn unhandled_intrinsic(
    control_flow_graph: &mut il::ControlFlowGraph,
    instruction: &capstone::Instr,
) -> Result<()> {
    let block_index = {
        let block = control_flow_graph.new_block()?;
        block.intrinsic(il::Intrinsic::new(
            instruction.mnemonic.clone(),
            format!("{} {}", instruction.mnemonic, instruction.op_str),
            Vec::new(),
            None,
            None,
            instruction.bytes.get(0..4).unwrap().to_vec(),
        ));
        block.index()
    };
    control_flow_graph.set_entry(block_index)?;
    control_flow_graph.set_exit(block_index)?;
    Ok(())
}
pub ( crate ) fn unhandled_intrinsic ( control_flow_graph : & mut il :: ControlFlowGraph , instruction : & capstone :: Instr , ) -> Result < ( ) > { let block_index = { let block = control_flow_graph . new_block ( ) ? ; block . intrinsic ( il :: Intrinsic :: new ( instruction . mnemonic . clone ( ) , format ! ( " " instruction mnemonic instruction op_str ) , Vec :: new ( ) , None , None , instruction . bytes . get ( 0 .. 4 ) . unwrap ( ) . to_vec ( ) , ) ) ; block . index ( ) } ; control_flow_graph . set_entry ( block_index ) ? ; control_flow_graph . set_exit ( block_index ) ? ; Ok ( ( ) ) }
A convenience function for turning unhandled instructions into intrinsics
A convenience function for turning unhandled instructions into intrinsics
control_flow_graph
&mut il::ControlFlowGraph
instruction
&capstone::Instr
control_flow_graph
&mut il::ControlFlowGraph
instruction
&capstone::Instr