Declarator object

Hi all:

I have a question. I am adding new attributes to C++ for functions. Consider the following examples:

void foo UNSW ( ) { }

UNSW is an additional attribute associated with the function “foo”. I am planning to add it to the Declarator object associated with the function so I can access it for type checking process. Is this the right direction to keep the attribute information for the Semantic analysis phase?

Yes, adding attributes somewhere within the declarator will be necessary.

Note that if you were willing to require this to fall before the identifier, you would be able to use one of the existing attribute syntaxes.