start flattenTerm in flattenSyntax