[aspectc-user] __declspec issues
HAWKINSJ at uk.ibm.com
Thu Aug 19 11:19:44 CEST 2004
Oh Dear - I think I might have got another MS specific issue.
Its now complaining about
c:/progra~1/micros~2/vc98/include/rpcdce.h:169: error: invalid declaration
Which appears to be a MS'ism ->
Any clues as to how to get around this one (without using the purchased
thanks for your help,
<daniel.lohmann at i
angen.de> John Hawkins/UK/IBM at IBMGB
18/08/2004 15:04 aspectc-user at aspectc.org
Re: [aspectc-user] __declspec
Most of the MS-specific language extensions are only parsed correctly
with the commercion version of ac++.exe, which is developed and sold by
pure-systems GmbH (http://www.pure-systems.com/) as part of their
As a workaround you may use "#ifdef __puma" which is defined during
parsing and weaving:
#define STORAGE_CLASS_INFO __declspec(dllexport)
or, as a more general solution
John Hawkins wrote:
>I'm trying to make ac++ trace sample work against a "simple" class.
>However, the class has the following code snippet in one of its included
>"STORAGE_CLASS_INFO int initialize_module(int bServer);"
>where STORAGE_CLASS_INFO is a macro for "__declspec(dllexport)" (a windows
>I'm getting the error -> error: invalid declaration near token `int'
>Why? I can only assume there is something wrong with ac++ handling of
>__declspec(dllexport)- but what?
>It's not an issue with the macro substitution because I have hardcoded it
>and still get the same error but i left it in for completeness incase
>someone knows otherwise.
>Compiler is MS VC6.0 (Yes, I know there are supposed to be issues but I
>only want to use it for trace at the moment so thought I could get away
>with it !)
More information about the aspectc-user