aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite
diff options
context:
space:
mode:
authorJason Merrill <jason@gcc.gnu.org>1998-12-07 07:27:51 -0500
committerJason Merrill <jason@gcc.gnu.org>1998-12-07 07:27:51 -0500
commitf070035e54ea019f78aad2db4132b71d1478a797 (patch)
tree920f9c615d284363c3c636566e76447b4a6c2fe8 /gcc/testsuite
parent2642b9bfd55db180d5e689d0fc7198dfc324c488 (diff)
downloadgcc-f070035e54ea019f78aad2db4132b71d1478a797.zip
gcc-f070035e54ea019f78aad2db4132b71d1478a797.tar.gz
gcc-f070035e54ea019f78aad2db4132b71d1478a797.tar.bz2
update
From-SVN: r24151
Diffstat (limited to 'gcc/testsuite')
-rw-r--r--gcc/testsuite/g++.old-deja/g++.benjamin/p15561.C194
-rw-r--r--gcc/testsuite/g++.old-deja/g++.brendan/visibility4.C4
-rw-r--r--gcc/testsuite/g++.old-deja/g++.ext/implicit1.C2
-rw-r--r--gcc/testsuite/g++.old-deja/g++.jason/ref5.C6
-rw-r--r--gcc/testsuite/g++.old-deja/g++.law/visibility11.C6
-rw-r--r--gcc/testsuite/g++.old-deja/g++.mike/dyncast1.C4
-rw-r--r--gcc/testsuite/g++.old-deja/g++.mike/dyncast2.C4
-rw-r--r--gcc/testsuite/g++.old-deja/g++.mike/dyncast3.C4
-rw-r--r--gcc/testsuite/g++.old-deja/g++.mike/net47.C2
-rw-r--r--gcc/testsuite/g++.old-deja/g++.mike/p784.C6
-rw-r--r--gcc/testsuite/g++.old-deja/g++.pt/lookup6.C4
-rw-r--r--gcc/testsuite/g++.old-deja/old-deja.exp2
12 files changed, 24 insertions, 214 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.benjamin/p15561.C b/gcc/testsuite/g++.old-deja/g++.benjamin/p15561.C
deleted file mode 100644
index 3dedd0c..0000000
--- a/gcc/testsuite/g++.old-deja/g++.benjamin/p15561.C
+++ /dev/null
@@ -1,194 +0,0 @@
-//980418 bkoz reduced from kumar's g++/15561
-// Build don't link:
-// prms-id: 15561
-
-extern int errno;
-extern int write (int, const void *, long unsigned int ) ;
-
-/* to debug
-#ifdef BUG
-*/
-//this crashes
-typedef long unsigned int size_t;
-//typedef unsigned long size_t;
-//this is ok
-//typedef unsigned int size_t;
-
-class exception {
-public:
- exception () { }
- virtual ~exception () { }
- virtual const char* what () const;
-};
-
-class bad_alloc : public exception {
-public:
- virtual const char* what() const throw() { return "bad_alloc"; }
-};
-
-struct nothrow_t {};
-extern const nothrow_t nothrow;
-
-typedef void (*new_handler)();
-new_handler set_new_handler (new_handler);
-
-void *operator new (size_t) throw (std::bad_alloc);
-void *operator new[] (size_t) throw (std::bad_alloc);
-void operator delete (void *) throw();
-void operator delete[] (void *) throw();
-void *operator new (size_t, const nothrow_t&) throw();
-void *operator new[] (size_t, const nothrow_t&) throw();
-void operator delete (void *, const nothrow_t&) throw();
-void operator delete[] (void *, const nothrow_t&) throw();
-inline void *operator new(size_t, void *place) throw() { return place; }
-inline void *operator new[](size_t, void *place) throw() { return place; }
-
-/* to debug
-#else
-#include <new>
-#endif
-*/
-
-//from kumar's ace file
-typedef unsigned long u_long;
-typedef int ACE_thread_t;
-typedef int ACE_hthread_t;
-typedef int ACE_thread_key_t;
-typedef int ssize_t;
-typedef int ACE_HANDLE;
-typedef ACE_HANDLE ACE_SOCKET;
-
-struct ACE_OVERLAPPED
-{
- u_long Internal;
- u_long InternalHigh;
- u_long Offset;
- u_long OffsetHigh;
- ACE_HANDLE hEvent;
-};
-
-struct strbuf {
- int maxlen;
- int len;
- char *buf;
-};
-
-struct flock {
- short l_type;
- short l_whence;
- long l_start;
- long l_len;
- short l_pid;
- short l_xxx;
-};
-
-class ACE_OS
-{
-public:
- struct ace_flock_t
- {
- void dump (void) const;
- struct flock lock_;
- ACE_HANDLE handle_;
- };
- static ssize_t write (ACE_HANDLE handle,
- const void *buf,
- size_t nbyte);
- static ssize_t write (ACE_HANDLE handle,
- const void *buf,
- size_t nbyte,
- ACE_OVERLAPPED *);
-
- static void *memcpy (void *t,
- const void *s,
- size_t len);
-
- static int putmsg (ACE_HANDLE handle,
- const struct strbuf *ctl,
- const struct strbuf *data,
- int flags);
-
- static ACE_thread_t NULL_thread;
- static ACE_hthread_t NULL_hthread;
- static ACE_thread_key_t NULL_key;
- static void mutex_lock_cleanup (void *mutex);
-private:
- ACE_OS (void);
-};
-
-
-
-inline ssize_t
-ACE_OS::write (ACE_HANDLE handle, const void *buf, size_t nbyte)
-{
- do {
- ssize_t ace_result_ = -1 ;
- ace_result_ = ace_result_;
- return ::write (handle, buf, nbyte) ; } while (0) ;
-}
-
-inline ssize_t
-ACE_OS::write (ACE_HANDLE handle, const void *buf, size_t nbyte,
- ACE_OVERLAPPED *overlapped)
-{
- overlapped = overlapped;
- return ACE_OS::write (handle, buf, nbyte);
-}
-
-
-inline int
-ACE_OS::putmsg (ACE_HANDLE handle, const struct strbuf *ctl,
- const struct strbuf *data, int flags)
-{
- {
- if (& flags )
- ;
- } ;
- if (ctl == 0 && data == 0)
- {
- errno = 22 ;
- return 0;
- }
-
- else if (ctl != 0)
- return ACE_OS::write (handle, ctl->buf, ctl->len);
- else if (data != 0)
- return ACE_OS::write (handle, data->buf, data->len);
- else
- {
- char *buf;
- do
- {
- buf = new char [ctl->len + data->len] ;
- if ( buf == 0)
- {
- errno = 12 ;
- return -1 ;
- }
- }
- while (0) ;
- ACE_OS::memcpy (buf, ctl->buf, ctl->len);
- ACE_OS::memcpy (buf + ctl->len, data->buf, data->len);
- int result = ACE_OS::write (handle, buf, ctl->len + data->len);
- delete [] buf;
- return result;
- }
-}
-
-int main()
-{
- return (1);
-}
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/gcc/testsuite/g++.old-deja/g++.brendan/visibility4.C b/gcc/testsuite/g++.old-deja/g++.brendan/visibility4.C
index b9de78f..1e7aea1 100644
--- a/gcc/testsuite/g++.old-deja/g++.brendan/visibility4.C
+++ b/gcc/testsuite/g++.old-deja/g++.brendan/visibility4.C
@@ -1,5 +1,4 @@
// Build don't link:
-// Special g++ Options: -w
// GROUPS passed visibility
template <class T>
class Feld {
@@ -8,7 +7,8 @@ public:
};
class Polynom : private Feld<double> {
-friend Polynom f(const Polynom&);
+ Polynom();
+ friend Polynom f(const Polynom&);
};
Polynom f(const Polynom& p) { return p; }
diff --git a/gcc/testsuite/g++.old-deja/g++.ext/implicit1.C b/gcc/testsuite/g++.old-deja/g++.ext/implicit1.C
index 399d232..33b9450 100644
--- a/gcc/testsuite/g++.old-deja/g++.ext/implicit1.C
+++ b/gcc/testsuite/g++.old-deja/g++.ext/implicit1.C
@@ -1,5 +1,5 @@
// test for implicit declaration
-// Special g++ Options: -w
+// Special g++ Options: -w -fpermissive
int
main ()
diff --git a/gcc/testsuite/g++.old-deja/g++.jason/ref5.C b/gcc/testsuite/g++.old-deja/g++.jason/ref5.C
index ca01353..0789522 100644
--- a/gcc/testsuite/g++.old-deja/g++.jason/ref5.C
+++ b/gcc/testsuite/g++.old-deja/g++.jason/ref5.C
@@ -1,8 +1,8 @@
// Build don't link:
-// Special g++ Options: -w
+
int i;
-int &const j = i;
-int &const f();
+int &const j = i; // ERROR - invalid const
+int &const f(); // ERROR - invalid const
void g ()
{
j = 1;
diff --git a/gcc/testsuite/g++.old-deja/g++.law/visibility11.C b/gcc/testsuite/g++.old-deja/g++.law/visibility11.C
index 9fa31dc..eeda777 100644
--- a/gcc/testsuite/g++.old-deja/g++.law/visibility11.C
+++ b/gcc/testsuite/g++.old-deja/g++.law/visibility11.C
@@ -37,7 +37,8 @@ public:
class D : public B, public C
{
-
+public:
+ D();
protected:
virtual void State(int a)
@@ -46,3 +47,6 @@ protected:
C::State(a);
}
};
+
+
+
diff --git a/gcc/testsuite/g++.old-deja/g++.mike/dyncast1.C b/gcc/testsuite/g++.old-deja/g++.mike/dyncast1.C
index fbcc489..3bddb3c 100644
--- a/gcc/testsuite/g++.old-deja/g++.mike/dyncast1.C
+++ b/gcc/testsuite/g++.old-deja/g++.mike/dyncast1.C
@@ -4,11 +4,11 @@
#include <typeinfo>
struct B {
- virtual f() { }
+ virtual int f() { }
};
struct D {
- virtual f() { }
+ virtual int f() { }
};
main() {
diff --git a/gcc/testsuite/g++.old-deja/g++.mike/dyncast2.C b/gcc/testsuite/g++.old-deja/g++.mike/dyncast2.C
index ba7a39e..fcf625e 100644
--- a/gcc/testsuite/g++.old-deja/g++.mike/dyncast2.C
+++ b/gcc/testsuite/g++.old-deja/g++.mike/dyncast2.C
@@ -6,11 +6,11 @@
#include <typeinfo>
struct B {
- virtual f() { }
+ virtual int f() { }
} ob;
struct D : public B {
- virtual f() { }
+ virtual int f() { }
} od;
main() {
diff --git a/gcc/testsuite/g++.old-deja/g++.mike/dyncast3.C b/gcc/testsuite/g++.old-deja/g++.mike/dyncast3.C
index ee775d0..627a7da 100644
--- a/gcc/testsuite/g++.old-deja/g++.mike/dyncast3.C
+++ b/gcc/testsuite/g++.old-deja/g++.mike/dyncast3.C
@@ -3,11 +3,11 @@
// Ensure that the return type of dynamic_cast is the real type.
struct B {
- virtual f() { }
+ virtual int f() { }
};
struct D : public B {
- virtual f() { }
+ virtual int f() { }
int i;
} od;
diff --git a/gcc/testsuite/g++.old-deja/g++.mike/net47.C b/gcc/testsuite/g++.old-deja/g++.mike/net47.C
index 431ff22..fc4a81f 100644
--- a/gcc/testsuite/g++.old-deja/g++.mike/net47.C
+++ b/gcc/testsuite/g++.old-deja/g++.mike/net47.C
@@ -1,5 +1,5 @@
// Build don't link:
-// Special g++ Options: -w
+// Special g++ Options: -w -fpermissive
class foo {};
class bar : foo {
diff --git a/gcc/testsuite/g++.old-deja/g++.mike/p784.C b/gcc/testsuite/g++.old-deja/g++.mike/p784.C
index 6af675d..ce61049 100644
--- a/gcc/testsuite/g++.old-deja/g++.mike/p784.C
+++ b/gcc/testsuite/g++.old-deja/g++.mike/p784.C
@@ -616,7 +616,7 @@ class ostream : public ios
void do_osfx();
public:
ostream();
- ostream(streambuf* sb, ostream* tied=((void *)0) );
+ ostream(streambuf* sb, ostream* tied=(__null) );
~ostream();
int opfx() { if (!good()) return 0; if (_tie) _tie->flush(); return 1; }
@@ -661,7 +661,7 @@ class istream : public ios
size_t _gcount;
public:
istream();
- istream(streambuf* sb, ostream*tied=((void *)0) );
+ istream(streambuf* sb, ostream*tied=(__null) );
~istream();
streambuf* istreambuf() const { return _strbuf; }
istream& get(char& c);
@@ -2238,7 +2238,7 @@ class strstreambuf : public streambuf {
public:
strstreambuf();
strstreambuf(int initial);
- strstreambuf(char *ptr, int size, char *pstart = ((void *)0) );
+ strstreambuf(char *ptr, int size, char *pstart = (__null) );
~strstreambuf();
int frozen() { return _frozen; }
void freeze(int n=1) { _frozen = n != 0; }
diff --git a/gcc/testsuite/g++.old-deja/g++.pt/lookup6.C b/gcc/testsuite/g++.old-deja/g++.pt/lookup6.C
index 0531109..ae1f5ca 100644
--- a/gcc/testsuite/g++.old-deja/g++.pt/lookup6.C
+++ b/gcc/testsuite/g++.old-deja/g++.pt/lookup6.C
@@ -10,6 +10,6 @@ template <class T> struct B : public A<T> {
// according to [temp.dep.type], `t' and `u' cannot be dependent types,
// and so there's no reason to delay lookup to specialization time.
void f(t p); // this is ::t [temp.dep]/3
- void f(typename A<T>::t p); // gets bogus error - redefinition - XFAIL *-*-*
- void g(u p); // ERROR - unknown type name - XFAIL *-*-*
+ void f(typename A<T>::t p); // gets bogus error - redefinition
+ void g(u p); // ERROR - unknown type name
};
diff --git a/gcc/testsuite/g++.old-deja/old-deja.exp b/gcc/testsuite/g++.old-deja/old-deja.exp
index 3567f51..70b822a 100644
--- a/gcc/testsuite/g++.old-deja/old-deja.exp
+++ b/gcc/testsuite/g++.old-deja/old-deja.exp
@@ -55,7 +55,7 @@ foreach file [lsort [find $srcdir/$subdir *.C]] {
# We don't want old-dejagnu.exp to have to know about all the global
# variables we use. For now we tell it about CXXFLAGS and LIBS and
# leave LDFLAGS alone.
- old-dejagnu $GXX_UNDER_TEST "$file" "" "$DEFAULT_CXXFLAGS" "-lstdc++"
+ old-dejagnu $GXX_UNDER_TEST "$file" "$tfile" "" "$DEFAULT_CXXFLAGS" "-lstdc++"
}
# The framework doesn't like to see any error remnants,