Added function to type/scope check assign statements