Remove the calloc-hack in the pretty printer + misc fixes.