Add debug output using GenericVisitor