[clang-cl] Diagnose duplicate uuids.
authorNico Weber <nicolasweber@gmx.de>
Tue, 13 Sep 2016 18:55:26 +0000 (18:55 +0000)
committerNico Weber <nicolasweber@gmx.de>
Tue, 13 Sep 2016 18:55:26 +0000 (18:55 +0000)
commit88f5ed9430a99667261c24c6082aa4c0ccc4df83
tree91df1209dd801e326f3b1758f61e459ab262a8e6
parent39ccd24126fcb99e95f15e49278a88adece2319a
[clang-cl] Diagnose duplicate uuids.

This mostly behaves cl.exe's behavior, even though clang-cl is stricter in some
corner cases and more lenient in others (see the included test).

To make the uuid declared previously here diagnostic work correctly, tweak
stripTypeAttributesOffDeclSpec() to keep attributes in the right order.

https://reviews.llvm.org/D24469

llvm-svn: 281367
clang/include/clang/Basic/DiagnosticSemaKinds.td
clang/include/clang/Sema/AttributeList.h
clang/include/clang/Sema/Sema.h
clang/lib/Parse/ParseDecl.cpp
clang/lib/Sema/SemaDecl.cpp
clang/lib/Sema/SemaDeclAttr.cpp
clang/test/SemaCXX/ms-uuid.cpp [new file with mode: 0644]