[aspectc-user] Compilation issues

Olaf Spinczyk olaf at ivs.cs.uni-magdeburg.de
Thu Aug 22 21:03:56 CEST 2002


On Thursday, 22. August 2002 10:39, you wrote:
> Hi Olaf,
> Back to AspectC questions -
> How can I keep a check on whether a particular variable is getting changed.
> Just as the call PCD and the execution PCD do you have any get PCD and set
> PCD like in AspectJ? PCD : Point-Cut Descriptor

If you look at the papers on the AspectC++ documentation web page you will 
find the pointcut functions "set" and "get". These two functions are not 
implemented, yet. Examples are set("int globalvar") or get("double C::attr"). 
We will implement these functions as soon as possible.

However, these pointcut functions will only detect access to variables if the 
code uses the variable *by name*. For example: globalvar=10 or foo->attr=1.0.
The reason for this restriction is the alias problem in C/C++. As far as I 
know a full variable access detection would require run-time checks on 
dereferenced pointers, which I would like to avoid. Perhaps this will become 
an optional feature in the future, but that is a long term goal.

Best regards,


More information about the aspectc-user mailing list