* [patch/testsuite/cp] classes.cc: extend scope of obj_with_enum
2004-03-19 0:09 [patch/testsuite/cp] classes.cc: extend scope of obj_with_enum Michael Elizabeth Chastain
@ 2004-03-09 17:33 ` Michael Elizabeth Chastain
0 siblings, 0 replies; 2+ messages in thread
From: Michael Elizabeth Chastain @ 2004-03-09 17:33 UTC (permalink / raw)
To: carlton, gdb-patches, vinschen
This patch fixes the problem reported by Corinna V in classes.exp.
I started with Corinna's patch and used Daniel J's suggestion to
hit a different member rather than writing on the same member twice.
This also lets me get rid of a TODO in classes.exp.
Tested on: native i686-pc-linux-gnu, gcc 2.95.3 3.3.3 HEAD, dwarf-2
and stabs+. With gcc HEAD -gdwarf-2, these results improved:
-FAIL: gdb.cp/classes.exp: print obj_with_enum (2)
-FAIL: gdb.cp/classes.exp: print obj_with_enum.priv_enum
-FAIL: gdb.cp/classes.exp: ptype obj_with_enum.priv_enum
-FAIL: gdb.cp/classes.exp: ptype obj_with_enum
+PASS: gdb.cp/classes.exp: print obj_with_enum (2)
+PASS: gdb.cp/classes.exp: print obj_with_enum.priv_enum
+PASS: gdb.cp/classes.exp: ptype obj_with_enum.priv_enum
+KFAIL: gdb.cp/classes.exp: ptype obj_with_enum (PRMS: gdb/57)
I am committing this now. Thanks Corinna! And let me know if it
doesn't work for you.
2004-03-09 Michael Chastain <mec.gnu@mindspring.com>
From Corinna Vinschen with modifications.
* gdb.cp/classes.cc (enums1): Add a line to extend scope of
local variable obj_with_enum.
* gdb.cp/classes.exp (test_enums): Remove TODO note about FAIL
results with obj_with_enum.
Michael C
Index: classes.cc
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.cp/classes.cc,v
retrieving revision 1.1
diff -c -3 -p -r1.1 classes.cc
*** classes.cc 9 Mar 2004 17:11:55 -0000 1.1
--- classes.cc 9 Mar 2004 17:25:23 -0000
***************
*** 1,6 ****
/* This testcase is part of GDB, the GNU debugger.
! Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001
Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
--- 1,6 ----
/* This testcase is part of GDB, the GNU debugger.
! Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2004
Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
*************** void enums1 ()
*** 453,458 ****
--- 453,459 ----
obj_with_enum.x = 0;
enums2 ();
obj_with_enum.priv_enum = ClassWithEnum::green;
+ obj_with_enum.x = 1;
}
class ClassParam {
Index: classes.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.cp/classes.exp,v
retrieving revision 1.8
diff -c -3 -p -r1.8 classes.exp
*** classes.exp 9 Mar 2004 17:11:55 -0000 1.8
--- classes.exp 9 Mar 2004 17:25:23 -0000
*************** proc test_enums {} {
*** 633,643 ****
gdb_test "next" ""
- # TODO: with gcc HEAD 2003-12-28 21:08:30 UTC -gdwarf-2,
- # gdb says that obj_with_enum is out of scope here and the
- # tests after this FAIL. This needs investigation.
- # -- chastain 2003-12-30
-
# print the object again
gdb_test "print obj_with_enum" \
--- 633,638 ----
^ permalink raw reply [flat|nested] 2+ messages in thread
* [patch/testsuite/cp] classes.cc: extend scope of obj_with_enum
@ 2004-03-19 0:09 Michael Elizabeth Chastain
2004-03-09 17:33 ` Michael Elizabeth Chastain
0 siblings, 1 reply; 2+ messages in thread
From: Michael Elizabeth Chastain @ 2004-03-19 0:09 UTC (permalink / raw)
To: carlton, gdb-patches, vinschen
This patch fixes the problem reported by Corinna V in classes.exp.
I started with Corinna's patch and used Daniel J's suggestion to
hit a different member rather than writing on the same member twice.
This also lets me get rid of a TODO in classes.exp.
Tested on: native i686-pc-linux-gnu, gcc 2.95.3 3.3.3 HEAD, dwarf-2
and stabs+. With gcc HEAD -gdwarf-2, these results improved:
-FAIL: gdb.cp/classes.exp: print obj_with_enum (2)
-FAIL: gdb.cp/classes.exp: print obj_with_enum.priv_enum
-FAIL: gdb.cp/classes.exp: ptype obj_with_enum.priv_enum
-FAIL: gdb.cp/classes.exp: ptype obj_with_enum
+PASS: gdb.cp/classes.exp: print obj_with_enum (2)
+PASS: gdb.cp/classes.exp: print obj_with_enum.priv_enum
+PASS: gdb.cp/classes.exp: ptype obj_with_enum.priv_enum
+KFAIL: gdb.cp/classes.exp: ptype obj_with_enum (PRMS: gdb/57)
I am committing this now. Thanks Corinna! And let me know if it
doesn't work for you.
2004-03-09 Michael Chastain <mec.gnu@mindspring.com>
From Corinna Vinschen with modifications.
* gdb.cp/classes.cc (enums1): Add a line to extend scope of
local variable obj_with_enum.
* gdb.cp/classes.exp (test_enums): Remove TODO note about FAIL
results with obj_with_enum.
Michael C
Index: classes.cc
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.cp/classes.cc,v
retrieving revision 1.1
diff -c -3 -p -r1.1 classes.cc
*** classes.cc 9 Mar 2004 17:11:55 -0000 1.1
--- classes.cc 9 Mar 2004 17:25:23 -0000
***************
*** 1,6 ****
/* This testcase is part of GDB, the GNU debugger.
! Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001
Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
--- 1,6 ----
/* This testcase is part of GDB, the GNU debugger.
! Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2004
Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
*************** void enums1 ()
*** 453,458 ****
--- 453,459 ----
obj_with_enum.x = 0;
enums2 ();
obj_with_enum.priv_enum = ClassWithEnum::green;
+ obj_with_enum.x = 1;
}
class ClassParam {
Index: classes.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.cp/classes.exp,v
retrieving revision 1.8
diff -c -3 -p -r1.8 classes.exp
*** classes.exp 9 Mar 2004 17:11:55 -0000 1.8
--- classes.exp 9 Mar 2004 17:25:23 -0000
*************** proc test_enums {} {
*** 633,643 ****
gdb_test "next" ""
- # TODO: with gcc HEAD 2003-12-28 21:08:30 UTC -gdwarf-2,
- # gdb says that obj_with_enum is out of scope here and the
- # tests after this FAIL. This needs investigation.
- # -- chastain 2003-12-30
-
# print the object again
gdb_test "print obj_with_enum" \
--- 633,638 ----
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2004-03-09 17:33 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-03-19 0:09 [patch/testsuite/cp] classes.cc: extend scope of obj_with_enum Michael Elizabeth Chastain
2004-03-09 17:33 ` Michael Elizabeth Chastain
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox