[Refactoring] PrettyPrintVisitor

Points:

1. Stop using helper functions inside PrettyPrintVisitor.
2. Reduce code duplication.