Rearrange nodes so that expressions are grouped together
Add separate name resolution module