Commit a89dd072 by Jason Merrill

fix noreturn warnings

From-SVN: r44350
parent 31d8a3ac
......@@ -5,7 +5,7 @@ public:
A(void) {}
private:
A(const A &) { abort(); } // ERROR -
const A& operator =(const A &) { abort(); }
const A& operator =(const A &) { abort(); } // WARNING - no return stmt XFAIL *-*-*
};
class B : public A {
......
......@@ -16,8 +16,8 @@ public:
class dictionary
{
public:
void *lookup(symbol s, void *v=0) { win = 1; }
void *lookup(const char *) {}
void lookup(symbol s, void *v=0) { win = 1; }
void lookup(const char *) {}
};
int main()
......
......@@ -3,6 +3,7 @@
int bar ()
{
throw 100;
return 0;
}
int main ()
......
// Test that unwinding properly restores SP.
// Contributed by Jason Merrill <jason@cygnus.com>
int f (int i)
void f (int i)
{
throw i;
}
......
......@@ -5,7 +5,7 @@
struct A
{
int f(int a) { }
int f(int a) { return 0; }
void f(int a, int b) { }
};
......
......@@ -25,6 +25,7 @@ public:
}
IncludeIt& operator=(const IncludeIt& i) {
myStrvec = i.myStrvec;
return *this;
}
private:
CopyMe myStrvec;
......
......@@ -2,10 +2,10 @@
// Build don't link:
struct A {
virtual int f () = 0;
virtual void f () = 0;
};
struct B: public A { int f () { } };
struct B: public A { void f () { } };
int main()
{
......
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