Added term_type to ast