added the grammar of functions