Added generic type to visitor

To accommodate evaluation of expressions through a visitor