
Aside from the type conversion dunders (e.g. `__bool__`), and the `and`, `or` and `in` operators, this is possible right now: You can create a `Symbol` class that returns another `Symbol` in the compatible operator dunder methods, while internally maintaining a list of (operator, args, kwargs). Then you can "replay" all the operations when you evaluate the symbol by in some way binding it to a value. You could even go as far as to build an AST from the operations list, and compile it to a function or lambda (its argument is the value you bind to), so you avoid the (significant) overhead of looping through the operations and applying then. It's unfortunate that there is no way to have e.g. `'spam' in my_symbolic_set` evaluate to something else than a boolean. Also, this approach will not work with everything else for which there is no dunder method, e.g. `math.sin(my_symbolic_value)` cannot be tricked into returning a Symbol.