simpleeval icon indicating copy to clipboard operation
simpleeval copied to clipboard

Support the "not" operator?

Open boxydog opened this issue 10 months ago • 1 comments

I have not yet started using simpleeval, but it looks like what I want.

I noticed it doesn't have the "not" operator, as in "not (a in b)".

I think I might need that.

Any plans?

I understand I can call out to a function, but that seems awkward.

boxydog avatar Feb 18 '25 21:02 boxydog

not is supported.

>>> import simpleeval
>>> 
>>> simpleeval.simpleeval("not True")
False
>>> simpleeval.simpleeval("not False")
True

This issue can be closed.

kurtmckee avatar Mar 13 '25 20:03 kurtmckee