Commit 07745bdb by Nathan Sidwell Committed by Nathan Sidwell

crash44.C: Remove XFAIL.

	* g++.old-deja/g++.pt/crash44.C: Remove XFAIL. Add ERROR.
	* g++.old-deja/g++.pt/friend38.C: Remove XFAIL. Add extra test.
	* g++.old-deja/g++.pt/friend45.C: New test.
	* g++.old-deja/g++.other/friend8.C: New test.

From-SVN: r35754
parent 80959c3f
2000-08-17 Nathan Sidwell <nathan@codesourcery.com>
* g++.old-deja/g++.pt/crash44.C: Remove XFAIL. Add ERROR.
* g++.old-deja/g++.pt/friend38.C: Remove XFAIL. Add extra test.
* g++.old-deja/g++.pt/friend45.C: New test.
* g++.old-deja/g++.other/friend8.C: New test.
2000-08-15 Richard Henderson <rth@cygnus.com> 2000-08-15 Richard Henderson <rth@cygnus.com>
* gcc.c-torture/execute/20000815-1.c: New test. * gcc.c-torture/execute/20000815-1.c: New test.
......
// Build don't link:
//
// Copyright (C) 2000 Free Software Foundation, Inc.
// Contributed by Nathan Sidwell 14 Aug 2000 <nathan@codesourcery.com>
// We failed to diagnose when a class friend declaration did not use an
// elaborated type specifier.
struct Y;
struct Z;
struct X
{
friend class Z;
friend Y; // ERROR - friend must use aggr tag
};
// Build don't link: // Build don't link:
// Origin: Mark Mitchell <mark@codesourcery.com> // Origin: Mark Mitchell <mark@codesourcery.com>
// crash test - XFAIL *-*-*
template <class T> template <class T>
struct S struct S
{ {
template <class U> template <class U>
friend S<U>; friend S<U>; // ERROR - friend must use tag
}; };
template struct S<int>; template struct S<int>;
...@@ -2,7 +2,8 @@ ...@@ -2,7 +2,8 @@
// Overly simplified from testcase by "B. K. Oxley" <binkley@bigfoot.com> // Overly simplified from testcase by "B. K. Oxley" <binkley@bigfoot.com>
template<class P> struct foo { template<class P, class Q> struct foo {
typedef P parent_type; typedef P parent_type;
friend parent_type; // ERROR - template parameters cannot be friends - XFAIL *-*-* friend parent_type; // ERROR - template parameters cannot be friends
friend Q; // ERROR - template parameters cannot be friends
}; };
// Build don't link:
//
// Copyright (C) 2000 Free Software Foundation, Inc.
// Contributed by Nathan Sidwell 14 Aug 2000 <nathan@codesourcery.com>
// bug 42. We ICE'd on instantiating a template with a bogus templated friend.
template<typename T> struct X
{
template<typename D> friend X<D>; // ERROR - friend must use aggr tag
};
X<int> g;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment