aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/g++.dg/warn/Wunused-local-typedefs-2.C
blob: 073e253c98ca580843b8cc34a7cfd8dd33620552 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
// Origin PR c++/33255
// { dg-options "-Wunused" } <-- should trigger -Wunused-local-typedefs
// { dg-do compile { target c++11 } }

template <typename C>
struct structure
{
    typename C::type val;
};

int
main()
{
  struct context
  {
      using type = int;
  };

  return structure<context>{42}.val;
}