[aspectc-user] Aspect Inheritance

Sven.Apel at metop-md.de Sven.Apel at metop-md.de
Wed May 28 09:41:43 CEST 2003


Hi,

Is it possible to inherit from an aspect with a non-pure-virtual
pointcut?
Something like this:

aspect aAspect
{
	pointcut virtual locking() =	execution("%
Attribute::Set(...)");
};

aspect bAspect : public aAspect
{
	pointcut locking() =	execution("% Attribute::Get(...)");
};


If I try I get the following Message:

u:\Entwicklung\Eigene Projekte\DB_Aspects\LockBaseAspect.h(46): error:
base aspect 'aAspect' is not abstract

If it is planned to support such inheritance, how can I reuse the
pointcut declaration of the base class?
I would appreciate something like that:

aspect bAspect : public aAspect
{
	pointcut locking() =	execution("% Attribute::Get(...)") &&
aAspect::locking();
};

best regards
Sven

p.s. Would it be nessecary in this case to declare the base class
pointcut as virtual?




More information about the aspectc-user mailing list