with this testcase.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@155301
91177308-0d34-0410-b5e6-
96231b3b80d8
// - a template, unless it is a function template that has
// internal linkage (Clause 14);
} else if (const TemplateDecl *temp = dyn_cast<TemplateDecl>(D)) {
- if (!OnlyTemplate)
- LV.merge(getLVForTemplateParameterList(temp->getTemplateParameters()));
-
+ LV.merge(getLVForTemplateParameterList(temp->getTemplateParameters()));
// - a namespace (7.3), unless it is declared within an unnamed
// namespace.
} else if (isa<NamespaceDecl>(D) && !D->isInAnonymousNamespace()) {
#define PROTECTED __attribute__((visibility("protected")))
#define DEFAULT __attribute__((visibility("default")))
+namespace test30 {
+ // When H is hidden, it should make X hidden, even if the template argument
+ // is not.
+ struct H {
+ };
+ template<H *T>
+ struct X {
+ };
+ H DEFAULT a;
+ X<&a> b;
+ // CHECK: _ZN6test301bE = global
+ // CHECK-HIDDEN: _ZN6test301bE = hidden global
+}
+
namespace test25 {
template<typename T>
struct X {