aboutsummaryrefslogtreecommitdiff
path: root/lib/AST/Decl.cpp
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2010-10-28 18:10:36 +0000
committerJohn McCall <rjmccall@apple.com>2010-10-28 18:10:36 +0000
commit479edbc8d0777e1bcf30ec3c90ebfb81bd5f4f28 (patch)
treeea67bedae1f92b4dc7aa3fc7e2e66c17ce1cf7d1 /lib/AST/Decl.cpp
parenta2e57698e2af5fd5ff37fde0ea7bcab4761534f3 (diff)
Don't apply -fvisibility-inlines-hidden to extern templates.
Part 2 of rdar://problem/8595231 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@117567 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/AST/Decl.cpp')
-rw-r--r--lib/AST/Decl.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/AST/Decl.cpp b/lib/AST/Decl.cpp
index 8526eccd65..19cfe9e119 100644
--- a/lib/AST/Decl.cpp
+++ b/lib/AST/Decl.cpp
@@ -456,7 +456,9 @@ static LVPair getLVForClassMember(const NamedDecl *D) {
// member functions get "hidden" visibility if they don't have an
// explicit visibility attribute.
if (!VA && MD->isInlined() && LV.second > HiddenVisibility &&
- D->getASTContext().getLangOptions().InlineVisibilityHidden)
+ D->getASTContext().getLangOptions().InlineVisibilityHidden &&
+ MD->getTemplateSpecializationKind()
+ != TSK_ExplicitInstantiationDeclaration)
LV.second = HiddenVisibility;
// Similarly for member class template specializations.