repro:
use z3::Sort;
fn main() {
let cfg = z3::Config::new();
let ctx = z3::Context::new(&cfg);
let res1 = Sort::enumeration(
&ctx,
"SameNameSort".into(),
&["A".into(), "B".into(),]
);
dbg!(&res1);
let res2 = Sort::enumeration(
&ctx,
"SameNameSort".into(),
&["C".into(), "D".into(),]
);
dbg!(&res2);
}
This manages to show the issue without triggering any UB, but doing anything interesting with res2 gives a nullptr exception
I'm not sure what exactly is supposed to happen, but at the very least this should panic!