Tsonnet #31 - Taking back control of equality

Cleaning up a messy equality implementation by introducing a new AST variant.