separate AST types from printer methods