Implementing print() methods within a library