You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been playing around with an idea for z3.BoolRef and wanted to see what you all think. Basically, it's about adding some operator overloads to make things a bit more slick and readable.
This lets you write logical expressions more like how you'd do it in plain Python, e.g. ~(x & y) == (~x | ~y). Feels cleaner to me, but I'm curious about what others think.
If this looks like something useful, I'm thinking of putting together a PR. I'm guessing the changes would go somewhere around here in the code:
But hey, I'm not entirely sure if that's the right spot or if there might be any unintended side effects, so any pointers or insights would be really helpful.
The text was updated successfully, but these errors were encountered:
Hi Z3 folks,
I've been playing around with an idea for
z3.BoolRef
and wanted to see what you all think. Basically, it's about adding some operator overloads to make things a bit more slick and readable.Here's the gist of it:
This lets you write logical expressions more like how you'd do it in plain Python, e.g.
~(x & y) == (~x | ~y)
. Feels cleaner to me, but I'm curious about what others think.If this looks like something useful, I'm thinking of putting together a PR. I'm guessing the changes would go somewhere around here in the code:
z3/src/api/python/z3/z3.py
Lines 1568 to 1586 in 9382b96
But hey, I'm not entirely sure if that's the right spot or if there might be any unintended side effects, so any pointers or insights would be really helpful.
The text was updated successfully, but these errors were encountered: