Add rewriting to Cypher AST

Currently rewrites patterns to name all elements, to move predicates in `MATCH` patterns into the associated `WHERE` clause, and to solve basic arithmetic expressions involving literals.