[aspectc-user] Re: How to use aspectc++ in C?

Olaf Spinczyk Olaf.Spinczyk at informatik.uni-erlangen.de
Fri Mar 7 10:29:52 CET 2003


Dear Peer,

On Friday 07 March 2003 01:00, Peer Haja wrote:
> Olaf,
> Thank you. The flag "-e c" works. Unfortunately, the
> aspect is still translated into C++ class.
>
> My current project involves an embedded system written
> in C code. What i am really interested is something
> that can process C source code instead of C++ for now.
> Can aspectc++ process and generate pure C code?

AspectC++ generates C++ code, e.g. an aspect becomes a class. It is a 
high-priority goal to support weaving in pure C files, but that requires some 
more time.

Some of our users were successful with compiling their manipulated C files 
with a c++ compiler, but there is not a c++ compiler available for every 
platform. Depending on your aspects an embedded c++ compiler might also be 
sufficient.

You could also try the COMO compiler, which translates C++ to C again, but if 
that's possible depends on your code. First of all you should try to find out 
if ac++ is able to transform your code in the expected way.

Yours,

Olaf



More information about the aspectc-user mailing list