Towards an evolutionary theory of language