summaryrefslogtreecommitdiffstats
path: root/gcc/testsuite/g++.dg/ext/visibility/template11.C
blob: fb47fe2aff256e87799bb8923a826e479beb5b88 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
// PR c++/51930
// { dg-require-visibility "" }
// { dg-options "-fvisibility=hidden" }
// { dg-final { scan-not-hidden "_ZN13template_testI4testE8functionEv" } }

struct test { };

template<typename T>
struct template_test
{
  __attribute__((visibility("default")))
  void function();
};

template<typename T>
void template_test<T>::function() { }

template
struct __attribute__((visibility("default")))
template_test<test>;
OpenPOWER on IntegriCloud