adding pieces of the translation function from nast to hhbc ast