Generifying syntax tree