inducer / pymbolic

A simple package to do symbolic math (focus on code gen and DSLs)
http://mathema.tician.de/software/pymbolic
Other
107 stars 25 forks source link

Mapper infrastructure for expression tree equality #29

Closed redrossa closed 3 years ago

redrossa commented 3 years ago

The PR only adds a new file for expression equality mapper for #28. Perhaps, pymbolic.primitives.Expression.__eq__ can also be changed to an implementation similar to pymbolic.primitives.Expression.__str__ with a make_equalizier method.

redrossa commented 3 years ago

I figured the current equality comparison implementation with __eq__ and is_equals is sufficient. Do you still want to continue with this idea?

inducer commented 3 years ago

Thanks for following up. I have no particular use for alternate implementations of __eq__, so if your need has disappeared, I'm OK with simply closing this.