added __eq__ for comparing expression structure, parser moved into a class, tests for nexted expressions against parser