[aspectc-user] Compiling problems with Visual Studio

Timo Lehtinen timo.lehtinen at progman.fi
Fri Mar 17 12:17:15 CET 2006


Hello! I've read about aspect-oriented programming some years ago and I was
interested in it, but at the time AspectC++ was still in beginning state.
Now we'd really like to add tracing etc. to our current projects (with
Visual Studio add-in by pure-systems) but we encountered compiling problems
- I'd be glad to have some info whether this can be fixed by editing
project/sources or is this a known parsing bug.

 

In our project we use STL and ATL, so that includes a lot of templates. I
got the following error messages when I tried to compile with tracing
example as an active aspect:

Compiling...

The system cannot find the file specified.

generating includes ... 

C:/Program Files/Microsoft Visual Studio
.NET/Vc7/atlmfc/include/atlstr.h(594): error: invalid member declaration
near token `*'

C:/Program Files/Microsoft Visual Studio
.NET/Vc7/atlmfc/include/atlplus.h(18): error: invalid declaration near token
`['

C:/Program Files/Microsoft Visual Studio
.NET/Vc7/atlmfc/include/atlplus.h(25): error: invalid declaration near token
`template'

C:/Program Files/Microsoft Visual Studio
.NET/Vc7/atlmfc/include/atlplus.h(51): error: invalid type in declaration of
parameter `%anon8465'

C:/Program Files/Microsoft Visual Studio
.NET/Vc7/atlmfc/include/atlwin.h(267): error: invalid type in declaration of
parameter `%anon9375'

C:/Program Files/Microsoft Visual Studio
.NET/Vc7/atlmfc/include/atlwin.h(268): error: invalid type in declaration of
parameter `%anon9377'

C:/Program Files/Microsoft Visual Studio
.NET/Vc7/atlmfc/include/atlwin.h(274): error: invalid type in declaration of
parameter `%anon9381'

C:/Program Files/Microsoft Visual Studio
.NET/Vc7/atlmfc/include/atlwin.h(1922): error: invalid declaration near
token `selectany'

AspectC++ generating includes failed

 

In that aspect we tried to add tracing to all functions. When we tried to
add tracing to only one free function compiling and linking succeeded. I
also tried to add tracing to all functions with VS's wizard-generated MFC
example project and it succeeded. I even tried to add some STL map things to
test whether this behaviour is related to template parsing, but it also
succeeded. When I tried to add tracing to VS's wizard-generated ATL example
project (DLL), compiling failed. Is there any workarounds for this
behaviour?

 

Best Regards,

Timo Lehtinen

SW manager

Progman Oy

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.aspectc.org/pipermail/aspectc-user/attachments/20060317/c3c6bdf9/attachment.html>


More information about the aspectc-user mailing list