first successful use of attribute grammar. the grammar seems to correct, and the parser is working with it