summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGBlocks.cpp
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2009-04-14 02:25:56 +0000
committerDaniel Dunbar <daniel@zuster.org>2009-04-14 02:25:56 +0000
commit0ca16601290fa748148bc9cba4b63fb07157ea2d (patch)
tree162e3061e09aed5495675f5b58882eecb08ea4d9 /clang/lib/CodeGen/CGBlocks.cpp
parentb76b745707fd86a94372b9d983cfda4f2399366c (diff)
downloadbcm5719-llvm-0ca16601290fa748148bc9cba4b63fb07157ea2d.tar.gz
bcm5719-llvm-0ca16601290fa748148bc9cba4b63fb07157ea2d.zip
Audit __private_extern__ handling.
- Exposed quite a few Sema issues and a CodeGen crash. - See FIXMEs in test case, and in SemaDecl.cpp (PR3983). I'm skeptical that __private_extern__ should actually be a storage class value. I think that __private_extern__ basically amounts to extern A __attribute__((visibility("hidden"))) and would be better off handled (a) as that, or (b) with an extra bit in the VarDecl. llvm-svn: 69020
Diffstat (limited to 'clang/lib/CodeGen/CGBlocks.cpp')
-rw-r--r--clang/lib/CodeGen/CGBlocks.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/clang/lib/CodeGen/CGBlocks.cpp b/clang/lib/CodeGen/CGBlocks.cpp
index d62379e4ef6..f1e74206819 100644
--- a/clang/lib/CodeGen/CGBlocks.cpp
+++ b/clang/lib/CodeGen/CGBlocks.cpp
@@ -608,8 +608,7 @@ CodeGenFunction::GenerateBlockFunction(const BlockExpr *BExpr,
++i) {
const VarDecl *VD = dyn_cast<VarDecl>(i->first);
- if (VD->getStorageClass() == VarDecl::Static
- || VD->getStorageClass() == VarDecl::Extern)
+ if (VD->getStorageClass() == VarDecl::Static || VD->hasExternalStorage())
LocalDeclMap[VD] = i->second;
}
OpenPOWER on IntegriCloud