Fixes to AST rewriter, added helpful rewriter labels to the test html