Follow up from #97: When MX symbols are used instead of SX, CasADi generates C functions with four inputs and two outputs (should be two inputs, one output).
CASADI_SYMBOL_EXPORT
int phi_ouwuhTtcvhAgzouqLDHE_work(
casadi_int *sz_arg,
casadi_int* sz_res,
casadi_int *sz_iw,
casadi_int *sz_w) {
if (sz_arg) *sz_arg = 4; // Should be 2
if (sz_res) *sz_res = 2; // Should be 1
if (sz_iw) *sz_iw = 0;
if (sz_w) *sz_w = 15;
return 0;
}
The rest of the Rust-to-C API assumes that CasADi function take two input arguments and return two output arguments, so we get memory problems.
Follow up from #97: When
MX
symbols are used instead ofSX
, CasADi generates C functions with four inputs and two outputs (should be two inputs, one output).The rest of the Rust-to-C API assumes that CasADi function take two input arguments and return two output arguments, so we get memory problems.