summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CodeGenModule.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.cpp')
-rw-r--r--clang/lib/CodeGen/CodeGenModule.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp
index 8a880516f66..0759abdd33f 100644
--- a/clang/lib/CodeGen/CodeGenModule.cpp
+++ b/clang/lib/CodeGen/CodeGenModule.cpp
@@ -286,6 +286,9 @@ void CodeGenModule::SetFunctionAttributes(const Decl *D,
if (D->getAttr<StdCallAttr>())
F->setCallingConv(llvm::CallingConv::X86_StdCall);
+
+ if (D->getAttr<RegparmAttr>())
+ ErrorUnsupported(D, "regparm attribute");
}
/// SetFunctionAttributesForDefinition - Set function attributes
@@ -308,6 +311,9 @@ void CodeGenModule::SetFunctionAttributesForDefinition(const Decl *D,
if (D->getAttr<NoinlineAttr>())
F->addFnAttr(llvm::Attribute::NoInline);
+
+ if (D->getAttr<RegparmAttr>())
+ ErrorUnsupported(D, "regparm attribute");
}
void CodeGenModule::SetMethodAttributes(const ObjCMethodDecl *MD,
OpenPOWER on IntegriCloud