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
Hi,
My aim is to replace & with function min() and replace | with max(). So, a & (b | c) should be rewritten as min(a, max(b,c)). I thought modifying the syntax tree is the way to go. Is it possible to modify ast() output and then convert back into an expression?
Hi,
My aim is to replace
&
with functionmin()
and replace|
withmax()
. So,a & (b | c)
should be rewritten asmin(a, max(b,c))
. I thought modifying the syntax tree is the way to go. Is it possible to modifyast()
output and then convert back into an expression?I'm sharing a small example:
The rewritten
express
should evaluate to5
andexpress_adv
should evaluate to4
. Expected expressions are :So, this is before:
and this is after:
The text was updated successfully, but these errors were encountered: