Function qdk_sim::c_api::set_noise_model_by_name [−][src]
#[no_mangle]
pub unsafe extern "C" fn set_noise_model_by_name(
sim_id: usize,
name: *const c_char
) -> i64
Expand description
Sets the noise model used by a given simulator instance, given a string containing the name of a built-in noise model.
Safety
This function is marked as unsafe as the caller is responsible for ensuring
that name
:
- Is a valid pointer to a null-terminated array of C characters.
- The pointer remains valid for at least the duration of the call.
- No other thread may modify the memory referenced by
new_model
for at least the duration of the call.