aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/CGDecl.cpp
diff options
context:
space:
mode:
authorFariborz Jahanian <fjahanian@apple.com>2009-03-30 20:32:06 +0000
committerFariborz Jahanian <fjahanian@apple.com>2009-03-30 20:32:06 +0000
commitba8639dd25b0bc9b9c49b305047d069342a126f2 (patch)
treedbc4ce327dee0b3cde31aea3a2016eca4f4728ae /lib/CodeGen/CGDecl.cpp
parent93e71455e932fb6436a154e2c805395558b7d54c (diff)
Code gen does not yet supports __asm__ on a variable
declaration. Reject it. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@68058 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGDecl.cpp')
-rw-r--r--lib/CodeGen/CGDecl.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/CodeGen/CGDecl.cpp b/lib/CodeGen/CGDecl.cpp
index acf16561cc..5a5bb62b06 100644
--- a/lib/CodeGen/CGDecl.cpp
+++ b/lib/CodeGen/CGDecl.cpp
@@ -60,6 +60,9 @@ void CodeGenFunction::EmitDecl(const Decl &D) {
/// EmitBlockVarDecl - This method handles emission of any variable declaration
/// inside a function, including static vars etc.
void CodeGenFunction::EmitBlockVarDecl(const VarDecl &D) {
+ if (D.getAttr<AsmLabelAttr>())
+ CGM.ErrorUnsupported(&D, "__asm__");
+
switch (D.getStorageClass()) {
case VarDecl::Static:
return EmitStaticBlockVarDecl(D);