+2002-07-07 Roger Sayle <roger@eyesopen.com>
+
+ * error.c (dump_function_name): Use DECL_TEMPLATE_RESULT for
+ constructor and destructor tests when passed a TEMPLATE_DECL.
+
2002-07-05 Jason Merrill <jason@redhat.com>
* cvt.c (cp_convert_to_pointer): Call force_fit_type for null
{
tree name = DECL_NAME (t);
+ if (TREE_CODE (t) == TEMPLATE_DECL)
+ t = DECL_TEMPLATE_RESULT (t);
+
/* Don't let the user see __comp_ctor et al. */
if (DECL_CONSTRUCTOR_P (t)
|| DECL_DESTRUCTOR_P (t))
+2002-07-07 Roger Sayle <roger@eyesopen.com>
+
+ * g++.dg/template/qualttp21.C: New test case.
+
2002-07-06 Alexandre Oliva <aoliva@redhat.com>
* gcc.c-torture/compile/20020706-1.c: New test.
* gcc.c-torture/compile/20020706-2.c: New test.
-2002-07-06 Brian R. Gaeke <brg@dgate.ORG>, Alexandre Oliva <aoliva@redhat.com>
+2002-07-06 Brian R. Gaeke <brg@dgate.ORG>
+ Alexandre Oliva <aoliva@redhat.com>
* g++.dg/warn/incomplete1.C: New test.
--- /dev/null
+// Copyright (C) 2002 Free Software Foundation
+// Contributed by Roger Sayle <roger@eyesopen.com>
+// { dg-do compile }
+
+template <class A>
+class foo {
+ int _foo;
+public:
+ foo() {}
+protected:
+ ~foo() {} // { dg-error "~foo" }
+};
+
+int main()
+{
+ foo<int> a; // { dg-error "context" }
+}