-
Notifications
You must be signed in to change notification settings - Fork 114
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add bindings for global params #242
Conversation
Hi, I was curious, what happens when you call https://z3prover.github.io/api/html/group__capi.html#ga9162ac23461bc67d1a0cde7c71f53111 with some bad string(Out of range chars or incorrect use of delimitation)? Does it panic or just silently fail? Do we expect these bindings to enforce the precondition or is it up to Z3? |
But we pass |
Here by bad string I meant something that violated the parameter naming assumption of Z3, as I linked to this line: Fair, maybe this also applies for Config but the Z3 docs don't have a similar line and I don't think support the '.' delimiter thing. |
Got it. Tested with invalid characters, nothing happens. |
A bit off-topic question, but do you know a way to set "global" parameters for specific context? |
Sorry, I don't know too much about this. Just fyi, if this is all through the Rust bindings, the Z3 error handler gets disabled so it might be silently failing when you are trying to set the parameter. #235 (comment) If that's your issue, then re-enabling it should shed light on the situation. |
Thanks for the info! |
@Pat-Lafon figured it out: let tactic = Tactic::new(&ctx, "sat");
let solver = tactic.solver();
let mut params = Params::new(&ctx);
params.set_bool("sat.euf", true);
solver.set_params(¶ms); But it's unrelated to the PR, I think it's ready for merge. |
Maybe worth pinging @waywardmonkeys to put this on his radar though I'm not sure how much time he has these days. |
Ready for merge? Here we go! |
@waywardmonkeys could you draft a new release? |
Let's see in 24 hours ... I'm away from home, so I won't be able to tomorrow. I just pushed some other changes that I had hanging around as well, so CI is backed up for a while. |
Resubmit of #199.