declarations.
Fixes pr13662.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@162360
91177308-0d34-0410-b5e6-
96231b3b80d8
if (Attr)
ProcessDeclAttributeList(S, NewClass, Attr);
+ if (PrevClassTemplate)
+ mergeDeclAttributes(NewClass, PrevClassTemplate->getTemplatedDecl());
+
AddPushedVisibilityAttribute(NewClass);
if (TUK != TUK_Friend)
NewTemplate->setInvalidDecl();
NewClass->setInvalidDecl();
}
- if (PrevClassTemplate)
- mergeDeclAttributes(NewClass, PrevClassTemplate->getTemplatedDecl());
ActOnDocumentableDecl(NewTemplate);
#pragma GCC visibility push(protected)
#pragma GCC visibility pop
}
+
+namespace pr13662 {
+#pragma GCC visibility push(hidden)
+ template<class T> class __attribute__((__visibility__("default"))) foo;
+ class bar { template<class T> friend class foo; };
+#pragma GCC visibility pop
+}