Parse domain declarations as function lists
Add more checks of domain declarations