Fixed to implement pretty-printing and other things