aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite/gdb.c++/virtfunc.exp
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/testsuite/gdb.c++/virtfunc.exp')
-rw-r--r--gdb/testsuite/gdb.c++/virtfunc.exp150
1 files changed, 134 insertions, 16 deletions
diff --git a/gdb/testsuite/gdb.c++/virtfunc.exp b/gdb/testsuite/gdb.c++/virtfunc.exp
index d0db755..e182744 100644
--- a/gdb/testsuite/gdb.c++/virtfunc.exp
+++ b/gdb/testsuite/gdb.c++/virtfunc.exp
@@ -34,15 +34,6 @@ if [get_compiler_info ${binfile} "c++"] {
return -1
}
-# if we are on HPUX and we are not compiled with gcc, then skip these tests.
-
-if [istarget hppa*-*-hpux*] {
- if {!$gcc_compiled} {
- continue
- }
-}
-
-
# Check to see if we have an executable to test. If not, then either we
# haven't tried to compile one, or the compilation failed for some reason.
@@ -106,6 +97,9 @@ proc test_ptype_of_classes {} {
-re "type = class VB \{${ws}public:${ws}int vb;${ws}VB & operator=\\(VB const &\\);${ws}VB\\(VB const &\\);${ws}VB\\(void\\);${ws}int fvb\\(void\\);${ws}virtual int vvb\\(void\\);${ws}\}.*$gdb_prompt $" {
pass "ptype VB"
}
+ -re "type = class VB \{${ws}public:${ws}int vb;${ws}int fvb \\(void\\);${ws}virtual int vvb \\(void\\);${ws}\}.*$gdb_prompt $" {
+ pass "ptype VB (aCC)"
+ }
-re "type = class VB \{${ws}public:${ws}int vb;((${ws}VB & operator=\\(VB const &\\);)|(${ws}VB\\(VB const &\\);)|(${ws}VB\\(void\\);)|(${ws}int fvb\\(void\\);)|(${ws}virtual int vvb\\(void\\);))*${ws}\}.*$gdb_prompt $" {
pass "ptype VB (obsolescent gcc or gdb)"
}
@@ -122,6 +116,9 @@ proc test_ptype_of_classes {} {
-re "type = class V : public VA, public VB \{${ws}public:${ws}int w;${ws}V & operator=\\(V const &\\);${ws}V\\(V const &\\);${ws}V\\(void\\);${ws}int f\\(void\\);${ws}virtual int vv\\(void\\);${ws}\}$nl$gdb_prompt $" {
pass "ptype V"
}
+ -re "type = class V : public VA, public VB \{${ws}public:${ws}int w;${ws}int f \\(void\\);${ws}virtual int vv \\(void\\);${ws}\}$nl$gdb_prompt $" {
+ pass "ptype V (aCC)"
+ }
-re "type = class V : public VA, public VB \{${ws}public:${ws}int w;((${ws}V & operator=\\(V const &\\);)|(${ws}V\\(V const &\\);)|(${ws}V\\(void\\);)|(${ws}int f\\(void\\);)|(${ws}virtual int vv\\(void\\);))*${ws}\}$nl$gdb_prompt $" {
pass "ptype V (obsolescent gcc or gdb)"
}
@@ -138,6 +135,9 @@ proc test_ptype_of_classes {} {
-re "type = class A : public virtual V \{${ws}private:${ws}V \[*\]+_vb\[\\\$\.\]+V;${ws}int a;${ws}public:${ws}A & operator=\\(A const &\\);${ws}A\\(int, A const &\\);${ws}A\\(int\\);${ws}virtual int f\\(void\\);${ws}\}$nl$gdb_prompt $" {
pass "ptype A"
}
+ -re "type = class A : public virtual V \{${ws}private:${ws}int a;${ws}public:${ws}virtual int f\\(void\\);${ws}\}$nl$gdb_prompt $" {
+ pass "ptype A (aCC)"
+ }
-re "type = class A : public virtual V \{${ws}private:${ws}V \[*\]+_vb\[\\\$\.\]+V;${ws}int a;${ws}public:((${ws}A & operator=\\(A const &\\);)|(${ws}A\\(int, A const &\\);)|(${ws}A\\(int\\);)|(${ws}virtual int f\\(void\\);))*${ws}\}$nl$gdb_prompt $" {
pass "ptype A (obsolescent gcc or gdb)"
}
@@ -161,6 +161,9 @@ proc test_ptype_of_classes {} {
-re "type = class B : public A \{${ws}private:${ws}int b;${ws}public:${ws}B & operator=\\(B const &\\);${ws}B\\(int, B const &\\);${ws}B\\(int\\);${ws}virtual int f\\(void\\);${ws}\}$nl$gdb_prompt $" {
pass "ptype B"
}
+ -re "type = class B : public A \{${ws}private:${ws}int b;${ws}public:${ws}virtual int f \\(void\\);${ws}\}$nl$gdb_prompt $" {
+ pass "ptype B (aCC)"
+ }
-re "type = class B : public A \{${ws}private:${ws}int b;${ws}public:((${ws}B & operator=\\(B const &\\);)|(${ws}B\\(int, B const &\\);)|(${ws}B\\(int\\);)|(${ws}virtual int f\\(void\\);))*${ws}\}$nl$gdb_prompt $" {
pass "ptype B (obsolescent gcc or gdb)"
}
@@ -177,6 +180,9 @@ proc test_ptype_of_classes {} {
-re "type = class C : public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}public:${ws}int c;${ws}C & operator=\\(C const &\\);${ws}C\\(int, C const &\\);${ws}C\\(int\\);${ws}\}$nl$gdb_prompt $" {
pass "ptype C"
}
+ -re "type = class C : public virtual V \{${ws}public:${ws}int c;${ws}\}$nl$gdb_prompt $" {
+ pass "ptype C (aCC)"
+ }
-re "type = class C : public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}public:${ws}int c;((${ws}C & operator=\\(C const &\\);)|(${ws}C\\(int, C const &\\);)|(${ws}C\\(int\\);))*${ws}\}$nl$gdb_prompt $" {
pass "ptype C (obsolescent gcc or gdb)"
}
@@ -193,6 +199,9 @@ proc test_ptype_of_classes {} {
-re "type = class AD \{${ws}public:${ws}AD & operator=\\(AD const &\\);${ws}AD\\(AD const &\\);${ws}AD\\(void\\);${ws}virtual int vg\\(void\\);${ws}\}$nl$gdb_prompt $" {
pass "ptype AD"
}
+ -re "type = class AD \{${ws}public:${ws}virtual int vg \\(void\\);${ws}\}$nl$gdb_prompt $" {
+ pass "ptype AD (aCC)"
+ }
-re "type = class AD \{${ws}public:((${ws}AD & operator=\\(AD const &\\);)|(${ws}AD\\(AD const &\\);)|(${ws}AD\\(void\\);)|(${ws}virtual int vg\\(void\\);))*${ws}\}$nl$gdb_prompt $" {
pass "ptype AD (obsolescent gcc or gdb)"
}
@@ -209,6 +218,9 @@ proc test_ptype_of_classes {} {
-re "type = class D : public AD, public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}public:${ws}int d;${ws}D & operator=\\(D const &\\);${ws}D\\(int, D const &\\);${ws}D\\(int\\);${ws}static void s\\(void\\);${ws}virtual int vg\\(void\\);${ws}virtual int vd\\(void\\);${ws}int fd\\(void\\);${ws}\}$nl$gdb_prompt $" {
pass "ptype D"
}
+ -re "type = class D : public AD, public virtual V \{${ws}public:${ws}int d;${ws}static void s\\(void\\);${ws}virtual int vg\\(void\\);${ws}virtual int vd\\(void\\);${ws}int fd\\(void\\);${ws}\}$nl$gdb_prompt $" {
+ pass "ptype D (aCC)"
+ }
-re "type = class D : public AD, public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}public:${ws}int d;((${ws}D & operator=\\(D const &\\);)|(${ws}D\\(int, D const &\\);)|(${ws}D\\(int\\);)|(${ws}static void s\\(void\\);)|(${ws}virtual int vg\\(void\\);)|(${ws}virtual int vd\\(void\\);)|(${ws}int fd\\(void\\);))*${ws}\}$nl$gdb_prompt $" {
pass "ptype D (obsolescent gcc or gdb)"
}
@@ -225,6 +237,9 @@ proc test_ptype_of_classes {} {
-re "type = class E : public B, public virtual V, public D, public C \{${ws}public:${ws}int e;${ws}E & operator=\\(E const &\\);${ws}E\\(int, E const &\\);${ws}E\\(int\\);${ws}virtual int f\\(void\\);${ws}virtual int vg\\(void\\);${ws}virtual int vv\\(void\\);${ws}\}$nl$gdb_prompt $" {
pass "ptype E"
}
+ -re "type = class E : public B, public virtual V, public D, public C \{${ws}public:${ws}int e;${ws}virtual int f \\(void\\);${ws}virtual int vg \\(void\\);${ws}virtual int vv \\(void\\);${ws}\}$nl$gdb_prompt $" {
+ pass "ptype E (aCC)"
+ }
-re "type = class E : public B, public virtual V, public D, public C \{${ws}public:${ws}int e;((${ws}E & operator=\\(E const &\\);)|(${ws}E\\(int, E const &\\);)|(${ws}E\\(int\\);)|(${ws}virtual int f\\(void\\);)|(${ws}virtual int vg\\(void\\);)|(${ws}virtual int vv\\(void\\);))*${ws}\}$nl$gdb_prompt $" {
pass "ptype E (obsolescent gcc or gdb)"
}
@@ -241,6 +256,9 @@ proc test_ptype_of_classes {} {
-re "type = class D : public AD, public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}public:${ws}int d;${ws}D & operator=\\(D const &\\);${ws}D\\(int, D const &\\);${ws}D\\(int\\);${ws}static void s\\(void\\);${ws}virtual int vg\\(void\\);${ws}virtual int vd\\(void\\);${ws}int fd\\(void\\);${ws}\}$nl$gdb_prompt $" {
pass "ptype dd"
}
+ -re "type = class D : public AD, public virtual V \{${ws}public:${ws}int d;${ws}static void s\\(void\\);${ws}virtual int vg\\(void\\);${ws}virtual int vd\\(void\\);${ws}int fd\\(void\\);${ws}\}$nl$gdb_prompt $" {
+ pass "ptype dd (aCC)"
+ }
-re "type = class D : public AD, public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}public:${ws}int d;((${ws}D & operator=\\(D const &\\);)|(${ws}D\\(int, D const &\\);)|(${ws}D\\(int\\);)|(${ws}static void s\\(void\\);)|(${ws}virtual int vg\\(void\\);)|(${ws}virtual int vd\\(void\\);)|(${ws}int fd\\(void\\);))*${ws}\}$nl$gdb_prompt $" {
pass "ptype dd (obsolescent gcc or gdb)"
}
@@ -257,6 +275,9 @@ proc test_ptype_of_classes {} {
-re "type = class D : public AD, public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}public:${ws}int d;${ws}D & operator=\\(D const &\\);${ws}D\\(int, D const &\\);${ws}D\\(int\\);${ws}static void s\\(void\\);${ws}virtual int vg\\(void\\);${ws}virtual int vd\\(void\\);${ws}int fd\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype ppd"
}
+ -re "type = class D : public AD, public virtual V \{${ws}public:${ws}int d;${ws}static void s\\(void\\);${ws}virtual int vg\\(void\\);${ws}virtual int vd\\(void\\);${ws}int fd\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
+ pass "ptype ppd (aCC)"
+ }
-re "type = class D : public AD, public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}public:${ws}int d;((${ws}D & operator=\\(D const &\\);)|(${ws}D\\(int, D const &\\);)|(${ws}D\\(int\\);)|(${ws}static void s\\(void\\);)|(${ws}virtual int vg\\(void\\);)|(${ws}virtual int vd\\(void\\);)|(${ws}int fd\\(void\\);))*${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype ppd (obsolescent gcc or gdb)"
}
@@ -273,6 +294,9 @@ proc test_ptype_of_classes {} {
-re "type = class AD \{${ws}public:${ws}AD & operator=\\(AD const &\\);${ws}AD\\(AD const &\\);${ws}AD\\(void\\);${ws}virtual int vg\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pAd"
}
+ -re "type = class AD \{${ws}public:${ws}virtual int vg \\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
+ pass "ptype pAd (aCC)"
+ }
-re "type = class AD \{${ws}public:((${ws}AD & operator=\\(AD const &\\);)|(${ws}AD\\(AD const &\\);)|(${ws}AD\\(void\\);)|(${ws}virtual int vg\\(void\\);))*${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pAd (obsolescent gcc or gdb)"
}
@@ -289,6 +313,9 @@ proc test_ptype_of_classes {} {
-re "type = class A : public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}int a;${ws}public:${ws}A & operator=\\(A const &\\);${ws}A\\(int, A const &\\);${ws}A\\(int\\);${ws}virtual int f\\(void\\);${ws}\}$nl$gdb_prompt $" {
pass "ptype a"
}
+ -re "type = class A : public virtual V \{${ws}private:${ws}int a;${ws}public:${ws}virtual int f\\(void\\);${ws}\}$nl$gdb_prompt $" {
+ pass "ptype a (aCC)"
+ }
-re "type = class A : public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}int a;${ws}public:((${ws}A & operator=\\(A const &\\);)|(${ws}A\\(int, A const &\\);)|(${ws}A\\(int\\);)|(${ws}virtual int f\\(void\\);))*${ws}\}$nl$gdb_prompt $" {
pass "ptype a (obsolescent gcc or gdb)"
}
@@ -305,6 +332,9 @@ proc test_ptype_of_classes {} {
-re "type = class B : public A \{${ws}private:${ws}int b;${ws}public:${ws}B & operator=\\(B const &\\);${ws}B\\(int, B const &\\);${ws}B\\(int\\);${ws}virtual int f\\(void\\);${ws}\}$nl$gdb_prompt $" {
pass "ptype b"
}
+ -re "type = class B : public A \{${ws}private:${ws}int b;${ws}public:${ws}virtual int f \\(void\\);${ws}\}$nl$gdb_prompt $" {
+ pass "ptype b (aCC)"
+ }
-re "type = class B : public A \{${ws}private:${ws}int b;${ws}public:((${ws}B & operator=\\(B const &\\);)|(${ws}B\\(int, B const &\\);)|(${ws}B\\(int\\);)|(${ws}virtual int f\\(void\\);))*${ws}\}$nl$gdb_prompt $" {
pass "ptype b (obsolescent gcc or gdb)"
}
@@ -321,6 +351,9 @@ proc test_ptype_of_classes {} {
-re "type = class C : public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}public:${ws}int c;${ws}C & operator=\\(C const &\\);${ws}C\\(int, C const &\\);${ws}C\\(int\\);${ws}\}$nl$gdb_prompt $" {
pass "ptype c"
}
+ -re "type = class C : public virtual V \{${ws}public:${ws}int c;${ws}\}$nl$gdb_prompt $" {
+ pass "ptype c (aCC)"
+ }
-re "type = class C : public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}public:${ws}int c;((${ws}C & operator=\\(C const &\\);)|(${ws}C\\(int, C const &\\);)|(${ws}C\\(int\\);))*${ws}\}$nl$gdb_prompt $" {
pass "ptype c (obsolescent gcc or gdb)"
}
@@ -337,6 +370,9 @@ proc test_ptype_of_classes {} {
-re "type = class D : public AD, public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}public:${ws}int d;${ws}D & operator=\\(D const &\\);${ws}D\\(int, D const &\\);${ws}D\\(int\\);${ws}static void s\\(void\\);${ws}virtual int vg\\(void\\);${ws}virtual int vd\\(void\\);${ws}int fd\\(void\\);${ws}\}$nl$gdb_prompt $" {
pass "ptype d"
}
+ -re "type = class D : public AD, public virtual V \{${ws}public:${ws}int d;${ws}static void s\\(void\\);${ws}virtual int vg\\(void\\);${ws}virtual int vd\\(void\\);${ws}int fd\\(void\\);${ws}\}$nl$gdb_prompt $" {
+ pass "ptype d (aCC)"
+ }
-re "type = class D : public AD, public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}public:${ws}int d;((${ws}D & operator=\\(D const &\\);)|(${ws}D\\(int, D const &\\);)|(${ws}D\\(int\\);)|(${ws}static void s\\(void\\);)|(${ws}virtual int vg\\(void\\);)|(${ws}virtual int vd\\(void\\);)|(${ws}int fd\\(void\\);))*${ws}\}$nl$gdb_prompt $" {
pass "ptype d (obsolescent gcc or gdb)"
}
@@ -353,6 +389,9 @@ proc test_ptype_of_classes {} {
-re "type = class E : public B, public virtual V, public D, public C \{${ws}public:${ws}int e;${ws}E & operator=\\(E const &\\);${ws}E\\(int, E const &\\);${ws}E\\(int\\);${ws}virtual int f\\(void\\);${ws}virtual int vg\\(void\\);${ws}virtual int vv\\(void\\);${ws}\}$nl$gdb_prompt $" {
pass "ptype e"
}
+ -re "type = class E : public B, public virtual V, public D, public C \{${ws}public:${ws}int e;${ws}virtual int f \\(void\\);${ws}virtual int vg \\(void\\);${ws}virtual int vv \\(void\\);${ws}\}$nl$gdb_prompt $" {
+ pass "ptype e (aCC)"
+ }
-re "type = class E : public B, public virtual V, public D, public C \{${ws}public:${ws}int e;((${ws}E & operator=\\(E const &\\);)|(${ws}E\\(int, E const &\\);)|(${ws}E\\(int\\);)|(${ws}virtual int f\\(void\\);)|(${ws}virtual int vg\\(void\\);)|(${ws}virtual int vv\\(void\\);))*${ws}\}$nl$gdb_prompt $" {
pass "ptype e (obsolescent gcc or gdb)"
}
@@ -369,6 +408,9 @@ proc test_ptype_of_classes {} {
-re "type = class V : public VA, public VB \{${ws}public:${ws}int w;${ws}V & operator=\\(V const &\\);${ws}V\\(V const &\\);${ws}V\\(void\\);${ws}int f\\(void\\);${ws}virtual int vv\\(void\\);${ws}\}$nl$gdb_prompt $" {
pass "ptype v"
}
+ -re "type = class V : public VA, public VB \{${ws}public:${ws}int w;${ws}int f \\(void\\);${ws}virtual int vv \\(void\\);${ws}\}$nl$gdb_prompt $" {
+ pass "ptype v (aCC)"
+ }
-re "type = class V : public VA, public VB \{${ws}public:${ws}int w;((${ws}V & operator=\\(V const &\\);)|(${ws}V\\(V const &\\);)|(${ws}V\\(void\\);)|(${ws}int f\\(void\\);)|(${ws}virtual int vv\\(void\\);))*${ws}\}$nl$gdb_prompt $" {
pass "ptype v (obsolescent gcc or gdb)"
}
@@ -385,6 +427,9 @@ proc test_ptype_of_classes {} {
-re "type = class VB \{${ws}public:${ws}int vb;${ws}VB & operator=\\(VB const &\\);${ws}VB\\(VB const &\\);${ws}VB\\(void\\);${ws}int fvb\\(void\\);${ws}virtual int vvb\\(void\\);${ws}\}$nl$gdb_prompt $" {
pass "ptype vb"
}
+ -re "type = class VB \{${ws}public:${ws}int vb;${ws}int fvb \\(void\\);${ws}virtual int vvb \\(void\\);${ws}\}$nl$gdb_prompt $" {
+ pass "ptype vb (aCC)"
+ }
-re "type = class VB \{${ws}public:${ws}int vb;((${ws}VB & operator=\\(VB const &\\);)|(${ws}VB\\(VB const &\\);)|(${ws}VB\\(void\\);)|(${ws}int fvb\\(void\\);)|(${ws}virtual int vvb\\(void\\);))*${ws}\}$nl$gdb_prompt $" {
pass "ptype vb (obsolescent gcc or gdb)"
}
@@ -401,6 +446,9 @@ proc test_ptype_of_classes {} {
-re "type = class A : public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}int a;${ws}public:${ws}A & operator=\\(A const &\\);${ws}A\\(int, A const &\\);${ws}A\\(int\\);${ws}virtual int f\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pAa"
}
+ -re "type = class A : public virtual V \{${ws}private:${ws}int a;${ws}public:${ws}virtual int f\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
+ pass "ptype pAa (aCC)"
+ }
-re "type = class A : public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}int a;${ws}public:((${ws}A & operator=\\(A const &\\);)|(${ws}A\\(int, A const &\\);)|(${ws}A\\(int\\);)|(${ws}virtual int f\\(void\\);))*${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pAa (obsolescent gcc or gdb)"
}
@@ -417,6 +465,9 @@ proc test_ptype_of_classes {} {
-re "type = class A : public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}int a;${ws}public:${ws}A & operator=\\(A const &\\);${ws}A\\(int, A const &\\);${ws}A\\(int\\);${ws}virtual int f\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pAe"
}
+ -re "type = class A : public virtual V \{${ws}private:${ws}int a;${ws}public:${ws}virtual int f\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
+ pass "ptype pAe (aCC)"
+ }
-re "type = class A : public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}int a;${ws}public:((${ws}A & operator=\\(A const &\\);)|(${ws}A\\(int, A const &\\);)|(${ws}A\\(int\\);)|(${ws}virtual int f\\(void\\);))*${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pAe (obsolescent gcc or gdb)"
}
@@ -433,6 +484,9 @@ proc test_ptype_of_classes {} {
-re "type = class B : public A \{${ws}private:${ws}int b;${ws}public:${ws}B & operator=\\(B const &\\);${ws}B\\(int, B const &\\);${ws}B\\(int\\);${ws}virtual int f\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pBe"
}
+ -re "type = class B : public A \{${ws}private:${ws}int b;${ws}public:${ws}virtual int f \\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
+ pass "ptype pBe (aCC)"
+ }
-re "type = class B : public A \{${ws}private:${ws}int b;${ws}public:((${ws}B & operator=\\(B const &\\);)|(${ws}B\\(int, B const &\\);)|(${ws}B\\(int\\);)|(${ws}virtual int f\\(void\\);))*${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pBe (obsolescent gcc or gdb)"
}
@@ -449,6 +503,9 @@ proc test_ptype_of_classes {} {
-re "type = class D : public AD, public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}public:${ws}int d;${ws}D & operator=\\(D const &\\);${ws}D\\(int, D const &\\);${ws}D\\(int\\);${ws}static void s\\(void\\);${ws}virtual int vg\\(void\\);${ws}virtual int vd\\(void\\);${ws}int fd\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pDd"
}
+ -re "type = class D : public AD, public virtual V \{${ws}public:${ws}int d;${ws}static void s\\(void\\);${ws}virtual int vg\\(void\\);${ws}virtual int vd\\(void\\);${ws}int fd\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
+ pass "ptype pDd (aCC)"
+ }
-re "type = class D : public AD, public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}public:${ws}int d;((${ws}D & operator=\\(D const &\\);)|(${ws}D\\(int, D const &\\);)|(${ws}D\\(int\\);)|(${ws}static void s\\(void\\);)|(${ws}virtual int vg\\(void\\);)|(${ws}virtual int vd\\(void\\);)|(${ws}int fd\\(void\\);))*${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pDd (obsolescent gcc or gdb)"
}
@@ -465,6 +522,9 @@ proc test_ptype_of_classes {} {
-re "type = class D : public AD, public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}public:${ws}int d;${ws}D & operator=\\(D const &\\);${ws}D\\(int, D const &\\);${ws}D\\(int\\);${ws}static void s\\(void\\);${ws}virtual int vg\\(void\\);${ws}virtual int vd\\(void\\);${ws}int fd\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pDe"
}
+ -re "type = class D : public AD, public virtual V \{${ws}public:${ws}int d;${ws}static void s\\(void\\);${ws}virtual int vg\\(void\\);${ws}virtual int vd\\(void\\);${ws}int fd\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
+ pass "ptype pDe (aCC)"
+ }
-re "type = class D : public AD, public virtual V \{${ws}private:${ws}V \[*\]+_vb.V;${ws}public:${ws}int d;((${ws}D & operator=\\(D const &\\);)|(${ws}D\\(int, D const &\\);)|(${ws}D\\(int\\);)|(${ws}static void s\\(void\\);)|(${ws}virtual int vg\\(void\\);)|(${ws}virtual int vd\\(void\\);)|(${ws}int fd\\(void\\);))*${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pDe (obsolescent gcc or gdb)"
}
@@ -481,6 +541,9 @@ proc test_ptype_of_classes {} {
-re "type = class V : public VA, public VB \{${ws}public:${ws}int w;${ws}V & operator=\\(V const &\\);${ws}V\\(V const &\\);${ws}V\\(void\\);${ws}int f\\(void\\);${ws}virtual int vv\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pVa"
}
+ -re "type = class V : public VA, public VB \{${ws}public:${ws}int w;${ws}int f \\(void\\);${ws}virtual int vv \\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
+ pass "ptype pVa (aCC)"
+ }
-re "type = class V : public VA, public VB \{${ws}public:${ws}int w;((${ws}V & operator=\\(V const &\\);)|(${ws}V\\(V const &\\);)|(${ws}V\\(void\\);)|(${ws}int f\\(void\\);)|(${ws}virtual int vv\\(void\\);))*${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pVa (obsolescent gcc or gdb)"
}
@@ -497,6 +560,9 @@ proc test_ptype_of_classes {} {
-re "type = class V : public VA, public VB \{${ws}public:${ws}int w;${ws}V & operator=\\(V const &\\);${ws}V\\(V const &\\);${ws}V\\(void\\);${ws}int f\\(void\\);${ws}virtual int vv\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pVv"
}
+ -re "type = class V : public VA, public VB \{${ws}public:${ws}int w;${ws}int f \\(void\\);${ws}virtual int vv \\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
+ pass "ptype pVv (aCC)"
+ }
-re "type = class V : public VA, public VB \{${ws}public:${ws}int w;((${ws}V & operator=\\(V const &\\);)|(${ws}V\\(V const &\\);)|(${ws}V\\(void\\);)|(${ws}int f\\(void\\);)|(${ws}virtual int vv\\(void\\);))*${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pVv (obsolescent gcc or gdb)"
}
@@ -513,6 +579,9 @@ proc test_ptype_of_classes {} {
-re "type = class V : public VA, public VB \{${ws}public:${ws}int w;${ws}V & operator=\\(V const &\\);${ws}V\\(V const &\\);${ws}V\\(void\\);${ws}int f\\(void\\);${ws}virtual int vv\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pVe"
}
+ -re "type = class V : public VA, public VB \{${ws}public:${ws}int w;${ws}int f \\(void\\);${ws}virtual int vv \\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
+ pass "ptype pVe (aCC)"
+ }
-re "type = class V : public VA, public VB \{${ws}public:${ws}int w;((${ws}V & operator=\\(V const &\\);)|(${ws}V\\(V const &\\);)|(${ws}V\\(void\\);)|(${ws}int f\\(void\\);)|(${ws}virtual int vv\\(void\\);))*${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pVe (obsolescent gcc or gdb)"
}
@@ -529,6 +598,9 @@ proc test_ptype_of_classes {} {
-re "type = class V : public VA, public VB \{${ws}public:${ws}int w;${ws}V & operator=\\(V const &\\);${ws}V\\(V const &\\);${ws}V\\(void\\);${ws}int f\\(void\\);${ws}virtual int vv\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pVd"
}
+ -re "type = class V : public VA, public VB \{${ws}public:${ws}int w;${ws}int f \\(void\\);${ws}virtual int vv \\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
+ pass "ptype pVd (aCC)"
+ }
-re "type = class V : public VA, public VB \{${ws}public:${ws}int w;((${ws}V & operator=\\(V const &\\);)|(${ws}V\\(V const &\\);)|(${ws}V\\(void\\);)|(${ws}int f\\(void\\);)|(${ws}virtual int vv\\(void\\);))*${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pVd (obsolescent gcc or gdb)"
}
@@ -545,6 +617,9 @@ proc test_ptype_of_classes {} {
-re "type = class AD \{${ws}public:${ws}AD & operator=\\(AD const &\\);${ws}AD\\(AD const &\\);${ws}AD\\(void\\);${ws}virtual int vg\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pADe"
}
+ -re "type = class AD \{${ws}public:${ws}virtual int vg \\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
+ pass "ptype pADe (aCC)"
+ }
-re "type = class AD \{${ws}public:((${ws}AD & operator=\\(AD const &\\);)|(${ws}AD\\(AD const &\\);)|(${ws}AD\\(void\\);)|(${ws}virtual int vg\\(void\\);))*${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pADe (obsolescent gcc or gdb)"
}
@@ -561,6 +636,9 @@ proc test_ptype_of_classes {} {
-re "type = class E : public B, public virtual V, public D, public C \{${ws}public:${ws}int e;${ws}E & operator=\\(E const &\\);${ws}E\\(int, E const &\\);${ws}E\\(int\\);${ws}virtual int f\\(void\\);${ws}virtual int vg\\(void\\);${ws}virtual int vv\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pEe"
}
+ -re "type = class E : public B, public virtual V, public D, public C \{${ws}public:${ws}int e;${ws}virtual int f \\(void\\);${ws}virtual int vg \\(void\\);${ws}virtual int vv \\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
+ pass "ptype pEe (aCC)"
+ }
-re "type = class E : public B, public virtual V, public D, public C \{${ws}public:${ws}int e;((${ws}E & operator=\\(E const &\\);)|(${ws}E\\(int, E const &\\);)|(${ws}E\\(int\\);)|(${ws}virtual int f\\(void\\);)|(${ws}virtual int vg\\(void\\);)|(${ws}virtual int vv\\(void\\);))*${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pEe (obsolescent gcc or gdb)"
}
@@ -577,6 +655,9 @@ proc test_ptype_of_classes {} {
-re "type = class VB \{${ws}public:${ws}int vb;${ws}VB & operator=\\(VB const &\\);${ws}VB\\(VB const &\\);${ws}VB\\(void\\);${ws}int fvb\\(void\\);${ws}virtual int vvb\\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pVB"
}
+ -re "type = class VB \{${ws}public:${ws}int vb;${ws}int fvb \\(void\\);${ws}virtual int vvb \\(void\\);${ws}\} \[*\]+$nl$gdb_prompt $" {
+ pass "ptype pVB (aCC)"
+ }
-re "type = class VB \{${ws}public:${ws}int vb;((${ws}VB & operator=\\(VB const &\\);)|(${ws}VB\\(VB const &\\);)|(${ws}VB\\(void\\);)|(${ws}int fvb\\(void\\);)|(${ws}virtual int vvb\\(void\\);))*${ws}\} \[*\]+$nl$gdb_prompt $" {
pass "ptype pVB (obsolescent gcc or gdb)"
}
@@ -616,6 +697,10 @@ proc test_virtual_calls {} {
(known failure with gcc cygnus-2.4.5-930417, skipping virtual calls)"
return 0
}
+ -re "Cannot resolve .* to any overloaded instance.*$gdb_prompt $" {
+ setup_xfail hppa*-*-* CLLbs16899
+ fail "print pAe->f()"
+ }
-re ".*$gdb_prompt $" { fail "print pAe->f()" }
timeout { fail "print pAe->f() (timeout)" }
eof { fail "print pAe->f() ($GDB dumped core) (FIXME)" ; gdb_virtfunc_restart; return }
@@ -624,15 +709,22 @@ proc test_virtual_calls {} {
send_gdb "print pAa->f()\n"
gdb_expect {
-re ".* = 1$nl$gdb_prompt $" { pass "print pAa->f()" }
+ -re "Cannot resolve .* to any overloaded instance.*$gdb_prompt $" {
+ setup_xfail hppa*-*-* CLLbs16899
+ fail "print pAa->f()"
+ }
-re ".*$gdb_prompt $" { fail "print pAa->f()" }
timeout { fail "print pAa->f() (timeout)" }
eof { fail "print pAa->f() ($GDB dumped core) (FIXME)" ; gdb_virtfunc_restart; return }
}
send_gdb "print pDe->vg()\n"
-# setup_xfail "*-*-*"
gdb_expect {
-re ".* = 202$nl$gdb_prompt $" { pass "print pDe->vg()" }
+ -re "Cannot resolve .* to any overloaded instance.*$gdb_prompt $" {
+ setup_xfail hppa*-*-* CLLbs16899
+ fail "print pDe->vg()"
+ }
-re ".*$gdb_prompt $" { fail "print pDe->vg()" }
timeout { fail "print pDe->vg() (timeout)" }
eof { fail "print pDe->vg() ($GDB dumped core) (FIXME)" ; gdb_virtfunc_restart; return }
@@ -641,24 +733,34 @@ proc test_virtual_calls {} {
send_gdb "print pADe->vg()\n"
gdb_expect {
-re ".* = 202$nl$gdb_prompt $" { pass "print pADe->vg()" }
+ -re "Cannot resolve .* to any overloaded instance.*$gdb_prompt $" {
+ setup_xfail hppa*-*-* CLLbs16899
+ fail "print pADe->vg()"
+ }
-re ".*$gdb_prompt $" { fail "print pADe->vg()" }
timeout { fail "print pADe->vg() (timeout)" }
eof { fail "print pADe->vg() ($GDB dumped core) (FIXME)" ; gdb_virtfunc_restart; return }
}
send_gdb "print pDd->vg()\n"
-# setup_xfail "*-*-*"
gdb_expect {
-re ".* = 101$nl$gdb_prompt $" { pass "print pDd->vg()" }
+ -re "Cannot resolve .* to any overloaded instance.*$gdb_prompt $" {
+ setup_xfail hppa*-*-* CLLbs16899
+ fail "print pDd->vg()"
+ }
-re ".*$gdb_prompt $" { fail "print pDd->vg()" }
timeout { fail "print pDd->vg() (timeout)" }
eof { fail "print pDd->vg() ($GDB dumped core) (FIXME)" ; gdb_virtfunc_restart; return }
}
send_gdb "print pEe->vvb()\n"
-# setup_xfail "*-*-*"
gdb_expect {
-re ".* = 411$nl$gdb_prompt $" { pass "print pEe->vvb()" }
+ -re "Cannot resolve .* to any overloaded instance.*$gdb_prompt $" {
+ setup_xfail hppa*-*-* CLLbs16899
+ fail "print pEe->vvb()"
+ }
-re ".*$gdb_prompt $" { fail "print pEe->vvb()" }
timeout { fail "print pEe->vvb() (timeout)" }
eof { fail "print pEe->vvb() ($GDB dumped core) (FIXME)" ; gdb_virtfunc_restart; return }
@@ -667,42 +769,58 @@ proc test_virtual_calls {} {
send_gdb "print pVB->vvb()\n"
gdb_expect {
-re ".* = 407$nl$gdb_prompt $" { pass "print pVB->vvb()" }
+ -re "Cannot resolve .* to any overloaded instance.*$gdb_prompt $" {
+ setup_xfail hppa*-*-* CLLbs16899
+ fail "print pVB->vvb()"
+ }
-re ".*$gdb_prompt $" { fail "print pVB->vvb()" }
timeout { fail "print pVB->vvb() (timeout)" }
eof { fail "print pVB->vvb() ($GDB dumped core) (FIXME)" ; gdb_virtfunc_restart; return }
}
send_gdb "print pBe->vvb()\n"
-# setup_xfail "*-*-*"
gdb_expect {
-re ".* = 411$nl$gdb_prompt $" { pass "print pBe->vvb()" }
+ -re "Cannot resolve .* to any overloaded instance.*$gdb_prompt $" {
+ setup_xfail hppa*-*-* CLLbs16899
+ fail "print pBe->vvb()"
+ }
-re ".*$gdb_prompt $" { fail "print pBe->vvb()" }
timeout { fail "print pBe->vvb() (timeout)" }
eof { fail "print pBe->vvb() ($GDB dumped core) (FIXME)" ; gdb_virtfunc_restart; return }
}
send_gdb "print pDe->vvb()\n"
-# setup_xfail "*-*-*"
gdb_expect {
-re ".* = 411$nl$gdb_prompt $" { pass "print pDe->vvb()" }
+ -re "Cannot resolve .* to any overloaded instance.*$gdb_prompt $" {
+ setup_xfail hppa*-*-* CLLbs16899
+ fail "print pDe->vvb()"
+ }
-re ".*$gdb_prompt $" { fail "print pDe->vvb()" }
timeout { fail "print pDe->vvb() (timeout)" }
eof { fail "print pDe->vvb() ($GDB dumped core) (FIXME)" ; gdb_virtfunc_restart; return }
}
send_gdb "print pEe->vd()\n"
-# setup_xfail "*-*-*"
gdb_expect {
-re ".* = 282$nl$gdb_prompt $" { pass "print pEe->vd()" }
+ -re "Cannot resolve .* to any overloaded instance.*$gdb_prompt $" {
+ setup_xfail hppa*-*-* CLLbs16899
+ fail "print pEe->vd()"
+ }
-re ".*$gdb_prompt $" { fail "print pEe->vd()" }
timeout { fail "print pEe->vd() (timeout)" }
eof { fail "print pEe->vd() ($GDB dumped core) (FIXME)" ; gdb_virtfunc_restart; return }
}
send_gdb "print pEe->fvb()\n"
-# setup_xfail "*-*-*"
gdb_expect {
-re ".* = 311$nl$gdb_prompt $" { pass "print pEe->fvb()" }
+ -re "Cannot resolve .* to any overloaded instance.*$gdb_prompt $" {
+ setup_xfail hppa*-*-* CLLbs16899
+ fail "print pEe->fvb()"
+ }
-re ".*$gdb_prompt $" { fail "print pEe->fvb()" }
timeout { fail "print pEe->fvb() (timeout)" }
eof { fail "print pEe->fvb() ($GDB dumped core) (FIXME)" ; gdb_virtfunc_restart; return }