add visitor pattern impl to earley ast