Remove old autovect-branch by moving to "dead" directory.
[official-gcc.git] / old-autovect-branch / gcc / testsuite / g++.dg / template / koenig5.C
blobd54bb75430c5f9f5299011afc5376380192e76c2
1 // { dg-do compile }
2 // Contributed by David Abrahams <dave at boost-consulting dot com>
3 // PR c++/14143: Koenig lookup should only look into template arguments only 
4 //  if the argument is a template-id.
6 namespace fu
8   template <class T>
9   struct bar
10   {
11       struct baz {};
12   };
15 namespace axe
17   struct handle {};
18   
19   template <class T>
20   char* f(T&);
23 namespace test
25   template <class T>
26   int f(T const&);
27   
28   template <class T>
29   int g(T x) { return f(x); }
30   
31   int x = g(fu::bar<axe::handle>::baz());