support for foreach, while and do