add code to raise attribute, name, syntax, type exceptions