summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/cpp0x/attributes-namespace5.C
blob: 6dbcf326061a2c459bfe3075cd8a6d2f7bf1bfa8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
// PR c++/79817 - attribute deprecated on namespace.
// { dg-do compile { target c++11 } }

namespace [[deprecated]] Y {
  void f();
  void f2(int);

  template<typename>
  struct S {
    void f3 ();
  };
}

void Y::f();
void Y::f() { }
void Y::f2(int);
void Y::f2([[maybe_unused]] int);
void Y::f2(int) { }
template <> void Y::S<int>::f3();
template <> void Y::S<int>::f3() { }