[cfe-commits] r110344 - in /cfe/trunk: lib/Parse/ParseDeclCXX.cpp test/Parser/MicrosoftExtensions.c
John McCall
rjmccall at apple.com
Thu Aug 5 10:13:11 PDT 2010
Author: rjmccall
Date: Thu Aug 5 12:13:11 2010
New Revision: 110344
URL: http://llvm.org/viewvc/llvm-project?rev=110344&view=rev
Log:
Allow multiple __declspec attributes after a class-key.
Patch by Francois Pichet!
Modified:
cfe/trunk/lib/Parse/ParseDeclCXX.cpp
cfe/trunk/test/Parser/MicrosoftExtensions.c
Modified: cfe/trunk/lib/Parse/ParseDeclCXX.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Parse/ParseDeclCXX.cpp?rev=110344&r1=110343&r2=110344&view=diff
==============================================================================
--- cfe/trunk/lib/Parse/ParseDeclCXX.cpp (original)
+++ cfe/trunk/lib/Parse/ParseDeclCXX.cpp Thu Aug 5 12:13:11 2010
@@ -646,7 +646,7 @@
AttrList = ParseGNUAttributes();
// If declspecs exist after tag, parse them.
- if (Tok.is(tok::kw___declspec))
+ while (Tok.is(tok::kw___declspec))
AttrList = ParseMicrosoftDeclSpec(AttrList);
// If C++0x attributes exist here, parse them.
Modified: cfe/trunk/test/Parser/MicrosoftExtensions.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Parser/MicrosoftExtensions.c?rev=110344&r1=110343&r2=110344&view=diff
==============================================================================
--- cfe/trunk/test/Parser/MicrosoftExtensions.c (original)
+++ cfe/trunk/test/Parser/MicrosoftExtensions.c Thu Aug 5 12:13:11 2010
@@ -3,6 +3,7 @@
int __stdcall func();
typedef int (__cdecl *tptr)();
void (*__fastcall fastpfunc)();
+struct __declspec(uuid("00000000-0000-0000-C000-000000000046")) __declspec(novtable) IUnknown {};
extern __declspec(dllimport) void __stdcall VarR4FromDec();
__declspec(deprecated) __declspec(deprecated) char * __cdecl ltoa( long _Val, char * _DstBuf, int _Radix);
__declspec(noalias) __declspec(restrict) void * __cdecl xxx( void * _Memory );
More information about the cfe-commits
mailing list