OSDN Git Service

Formatting fixes.
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / g++.old-deja / g++.pt / typename24.C
1 // { dg-do assemble  }
2 // Origin: Mark Mitchell <mark@codesourcery.com>
3
4 class ostream;
5
6 extern ostream& cout;
7
8 class Foo { };
9
10 ostream &operator<<(ostream &os, const Foo &)
11 {
12   return os;
13 }
14
15 template<class T>
16 const typename T::fooz &operator<<(const Foo &, const T &t)
17 {
18   return t;
19 }
20
21 int main()
22 {
23   Foo foo;
24
25   cout << foo;
26 }