diff options
author | Roman Divacky <rdivacky@freebsd.org> | 2011-08-05 16:37:22 +0000 |
---|---|---|
committer | Roman Divacky <rdivacky@freebsd.org> | 2011-08-05 16:37:22 +0000 |
commit | 8e68f1c8a2919ea83c2053731d6011074f1062e1 (patch) | |
tree | 0ba49911c7387d0ede5b49b80a3686dd149da89d /lib | |
parent | c268434b332bbe57950d977633369bf5822d9554 (diff) |
Let attribute((cdecl)) and company override -mrtd default calling convention.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@136971 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Sema/SemaType.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Sema/SemaType.cpp b/lib/Sema/SemaType.cpp index 2f93642d2f..f429449acf 100644 --- a/lib/Sema/SemaType.cpp +++ b/lib/Sema/SemaType.cpp @@ -3482,7 +3482,7 @@ static bool handleFunctionTypeAttr(TypeProcessingState &state, return true; } - if (CCOld != CC_Default) { + if (CCOld != (S.LangOpts.MRTD ? CC_X86StdCall : CC_Default)) { // Should we diagnose reapplications of the same convention? S.Diag(attr.getLoc(), diag::err_attributes_are_not_compatible) << FunctionType::getNameForCallConv(CC) |