2003-12-26 Guilhem Lavaux <guilhem@kaffe.org>
[official-gcc.git] / gcc / testsuite / g++.old-deja / g++.brendan / ptrmem3.C
blob4f78039d4fd4b946a9c7c850a7a18083d9125c90
1 // { dg-do assemble  }
2 // GROUPS passed pointers-to-members
3 template<class T> class TemplA {
4     T t;
5 };
8 template<class T> class TemplB {
9 public:    
10     typedef void (T::*TClassMethod)();
12 private:
14    This line should not crash cuz of the get_decl_list change in this:
15         * cp-tree.c (list_hash_lookup_or_cons): Make sure the type doesn't
16         have TYPE_PTRMEMFUNC_P set before we try to build its
17         CLASSTYPE_ID_AS_LIST.
18         (get_decl_list): Likewise, when trying to read it.
20     TemplA<TClassMethod> Tmethod;  
24 class C {
25     int a;
28 int main(int, char**) {
30     TemplB<C> test;