OSDN Git Service

* class.c (resolve_address_of_overloaded_function): Don't
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / g++.old-deja / g++.other / typename1.C
1 // { dg-do assemble  }
2 // { dg-options "-pedantic -Wno-deprecated" }
3 // This code snippet should be rejected with -pedantic
4 // Based on a test case by Louidor Erez <s3824888@techst02.technion.ac.il>
5
6
7 template<class T>
8 class Vector {
9 public:
10   typedef T* iterator;
11 };
12
13 template<class T>
14 void f()
15 {
16   Vector<T>::iterator i = 0; // { dg-error "typename" } missing typename
17 } // { dg-error "expected" "" { target *-*-* } 16 }