It seems most of the ATL/COM attributes from 2003 -> 2005 have been broken. Im using the RTM. I just compiled a COM/ATL project which works fine in 2k3 but in 2k5 i get lots of errors with attributes. A classic is:
[
uuid("xxx-blah-xxx")
]
class myForwardDeclaredClass;
That no longer works. I find I have to do:
class __declspec(uuid("xxx-blah-xxx")) myForwardDeclaredClass;
There is no documentation or acknowledgement of this problem anywhere. I wonder if anyone at MS actually tried compiling any COM/ATL projects in 2k5 before it shipped
Quite simply, unless breaking changes are documented then a project in 2k3 should compile in 2k5. I have yet to find any such documentation.

com/atl attributes broken
Michael Mac
Thanks,
Ayman Shoukry
VC++ team
Waleed Seada
[ uuid("...") ]
class CFoo {};
...
const GUID &myGuid = __uuidof(CFoo);
works correct!
Just checked with .NET 2005 Beta 2!
Denton
Berni P.
Was this ever resolved
Dan
DaveC#
As for the code, I will have to come back later with a sample that shows the problem. The test the 2nd poster did was not quite what I meant - you also need to fully delclare the attributed class elsewhere in the project. You get errors C3121 + C3163.
Michel Jongbloed
Please note a bug is now lodged for this issue on Connect:
http://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx FeedbackID=143956
bazinou
jayww
It works if the class is defined completely and not a forward declaration is used!
Try to file a bug at
http://lab.msdn.microsoft.com/productfeedback
If you want I can do it for you!
Dogbrain
amselem
Take a look at such link since it could be a related issue.
Thanks,
Ayman Shoukry
VC++ Team
Douwe
I have created two identical projects - one that compiles in 2k3 and one that fails in 2k5. Please can you give me an email address so I can send these samples projects as attachments.
HemaR